Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

optimize: optimize the speed of buildLockKey #714

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

FinnTew
Copy link
Contributor

@FinnTew FinnTew commented Nov 24, 2024

What this PR does:

optimize the speed of buildLockKey

K: The number of primary keys
M: The number of columns
N: The number of rows

Original time complexity: $O(N \times M \times K)$
Optimized time complexity: $O(N \times K)$

Which issue(s) this PR fixes:

Fixes #696

Special notes for your reviewer:

It has been tested locally and can pass the corresponding unit test.

Does this PR introduce a user-facing change?:

NONE

@luky116
Copy link
Contributor

luky116 commented Nov 27, 2024

把单元测试也完善下

@FinnTew
Copy link
Contributor Author

FinnTew commented Nov 28, 2024

把单元测试也完善下

好的

Copy link
Contributor

@Code-Fight Code-Fight left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

解决下 Quality Gate的重复代码问题

Copy link
Contributor

@Code-Fight Code-Fight left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[seata-java] optimize: optimize the speed of buildLockKey
3 participants