-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
executor,session: reimplement lock->put by SetLockedKeyValue
#42642
executor,session: reimplement lock->put by SetLockedKeyValue
#42642
Conversation
Signed-off-by: zyguan <zhongyangguan@gmail.com>
[REVIEW NOTIFICATION] This pull request has been approved by:
To complete the pull request process, please ask the reviewers in the list to review by filling The full list of commands accepted by this bot can be found here. Reviewer can indicate their review by submitting an approval review. |
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.
The return value is never used?
Signed-off-by: zyguan <zhongyangguan@gmail.com>
Do you mean the return of |
Signed-off-by: zyguan <zhongyangguan@gmail.com>
@@ -2913,6 +2913,40 @@ func TestChangeLockToPut(t *testing.T) { | |||
tk.MustExec("admin check table t1") | |||
} | |||
|
|||
func TestIssue28011(t *testing.T) { |
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.
We don't have a test to cover the effect of changing, maybe it's needed to tested by hand.
/merge |
This pull request has been accepted and is ready to merge. Commit hash: e33891f
|
…ap#42642) ref pingcap#28011 Signed-off-by: zyguan <zhongyangguan@gmail.com>
What problem does this PR solve?
Issue Number: ref #28011
Problem Summary: as described in #28011 , kv pairs converted from locks is visible to union-scan, which leads to duplicated rows (one from snapshot and the other from mem-index-reader).
What is changed and how it works?
Instead of writing membuf directly, cache locked key-value pairs that might be converted to PUT separately, and merge them on commit.
Check List
Tests
Side effects
Documentation
Release note
Please refer to Release Notes Language Style Guide to write a quality release note.