-
Notifications
You must be signed in to change notification settings - Fork 8.8k
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: remove the branch registration operation of the XA read-only transaction #6826
Conversation
…n and other related operations
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## 2.x #6826 +/- ##
============================================
+ Coverage 52.30% 52.34% +0.03%
- Complexity 6405 6421 +16
============================================
Files 1083 1083
Lines 37846 37916 +70
Branches 4489 4495 +6
============================================
+ Hits 19795 19846 +51
- Misses 16081 16097 +16
- Partials 1970 1973 +3
|
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
rm-datasource/src/main/java/org/apache/seata/rm/datasource/xa/ConnectionProxyXA.java
Outdated
Show resolved
Hide resolved
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
…n and other related operations
Ⅰ. Describe what this PR did
XA模式下。如果是只读事务就不注册分支及xa的任何操作
In XA mode, if it is a read-only transaction, the branch and any operation of xa will not be registered.
Ⅱ. Does this pull request fix one issue?
Ⅲ. Why don't you add test cases (unit test/integration test)?
Ⅳ. Describe how to verify it
Manually set the connection's readOnly to true or set the annotation @transactional(readOnly = true) in the Spring framework
Ⅴ. Special notes for reviews