txn: reject unsupported shared lock transaction paths#1956
txn: reject unsupported shared lock transaction paths#1956cfzjywxk wants to merge 1 commit intotikv:masterfrom
Conversation
Signed-off-by: cfzjywxk <cfzjywxk@gmail.com>
|
ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughThis PR enforces shared lock transaction mode compatibility constraints in client-go. Changes prevent shared locks from being used in pipelined or aggressive locking transactions, disable async commit and 1PC for shared lock transactions, and reject shared-lock keys as the transaction primary key. Test coverage validates all constraints. ChangesShared lock transaction mode constraints
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related issues
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@wfxr PTAL |
[LGTM Timeline notifier]Timeline:
|
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: you06 The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Issue Number: close #1955
Problem Summary:
Shared lock transactions should not enter commit or lock paths that are incompatible with shared locks. TiDB issue: pingcap/tidb#66154
What is changed:
Tests:
go test ./txnkv/transaction -run "TestLockKeys|TestSharedLockCommitterIncompatibilities"go test ./txnkv/transactiongit diff --checkSummary by CodeRabbit
Bug Fixes
Tests