-
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
autoid_service: fix the result of NextGlobalAutoID() for AUTO_ID_CACHE=1 #46550
Conversation
Hi @tiancaiamao. Thanks for your PR. PRs from untrusted users cannot be marked as trusted with I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
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
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## master #46550 +/- ##
================================================
- Coverage 73.3358% 72.6855% -0.6503%
================================================
Files 1310 1333 +23
Lines 394421 400982 +6561
================================================
+ Hits 289252 291456 +2204
- Misses 86761 91067 +4306
- Partials 18408 18459 +51
Flags with carried forward coverage won't be shown. Click here to find out more.
|
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
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: bb7133, YangKeao The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
@tiancaiamao: The following test failed, say
Full PR test history. Your PR dashboard. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
In response to a cherrypick label: new pull request created to branch |
In response to a cherrypick label: new pull request created to branch |
What problem does this PR solve?
Issue Number: close #46545
Problem Summary:
What is changed and how it works?
After #39041 the row id and auto increment id use different key.
Here IncrementID should be used.
Check List
Tests
Follow the step in issue #46545
It's not easy to integration test for this, since the bug need a tidb restart to trigger.
After the autoid service initialized, the cached value is used and the code logic does not go the buggy line.
https://github.com/pingcap/tidb/pull/46550/files#diff-617839a099f419c84781f44a2286d763780a446a701eac0a440c7c579378706cR457-R462
Side effects
Documentation
Release note
Please refer to Release Notes Language Style Guide to write a quality release note.