-
Notifications
You must be signed in to change notification settings - Fork 753
gc: Add a temporary solution to make service safe point compatible with the new txn safe point mechanism #9407
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
gc: Add a temporary solution to make service safe point compatible with the new txn safe point mechanism #9407
Conversation
…th the new txn safe point mechanism Signed-off-by: MyonKeminta <MyonKeminta@users.noreply.github.com>
|
Skipping CI for Draft Pull Request. |
|
/retest |
Codecov ReportAttention: Patch coverage is
❌ Your patch status has failed because the patch coverage (59.09%) is below the target coverage (74.00%). You can increase the patch coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## master #9407 +/- ##
==========================================
+ Coverage 76.16% 76.20% +0.04%
==========================================
Files 478 478
Lines 74782 74794 +12
==========================================
+ Hits 56954 56999 +45
+ Misses 14296 14276 -20
+ Partials 3532 3519 -13
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: okJiang, rleungx 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 |
|
/retest |
4 similar comments
|
/retest |
|
/retest |
|
/retest |
|
/retest |
What problem does this PR solve?
Issue Number: ref #8978
The
UpdateServiceGCSafePoint(V2)methods are going to be deprecated and replaced by a compatibility layer over theGCStatesManager, which is expected to be done in #9292. However it's not sure when #9292 can be merged. Now, there still exist usages ofUpdateServiceGCSafePoint(V2), but TiDB won't register the service safe point of"gc_worker"anymore. This causes that when other components tries to register their service safe points, the"gc_worker"'s service safe point may be automatically initialized as 0, allowing data access that breaks the constraint of txn safe point.This PR is a temporary solution to this problem, and should be finally cleaned up in #9292. This PR makes the service safe point of
"gc_worker"always be initalized to the same value as the current txn safe point.What is changed and how does it work?
Check List
Tests
Code changes
Side effects
Related changes
pingcap/docs/pingcap/docs-cn:pingcap/tiup:Release note