-
Notifications
You must be signed in to change notification settings - Fork 8.7k
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: reduce server rpc with db #1823
optimize: reduce server rpc with db #1823
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #1823 +/- ##
============================================
- Coverage 54.94% 54.84% -0.1%
+ Complexity 2358 2357 -1
============================================
Files 422 422
Lines 14259 14314 +55
Branches 1673 1687 +14
============================================
+ Hits 7834 7850 +16
- Misses 5679 5713 +34
- Partials 746 751 +5
|
…com/zjinlei/seata into bugfix/db-globalstatus-inconsistent
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, the performance of the lock is greatly improved compared to the previous one, but which rowkey becomes less clear when a lock conflict occurs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
acquireLock method check lock , better with StringJoiner.
StringJoiner sj = new StringJoiner(","); for (LockDO lockDO : lockDOs) { sj.add("?"); }
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Ⅰ. Describe what this PR did
1.reduce rpc with db when branchRegister and getGolbalStatus
2.reduce rpc with db when batch locks insert
Ⅱ. Does this pull request fix one issue?
fixes #1818
Ⅲ. Why don't you add test cases (unit test/integration test)?
Ⅳ. Describe how to verify it
Ⅴ. Special notes for reviews