-
Notifications
You must be signed in to change notification settings - Fork 288
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
owner: Modified the update strategy of gcSafePoint (#1731) #1759
Conversation
/type cherry-pick-for-release-5.0 |
/lgtm |
[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 writing |
/merge |
This pull request has been accepted and is ready to merge. Commit hash: dff895d
|
/run-kafka-tests |
/run-integration-tests |
/run-kafka-tests |
1 similar comment
/run-kafka-tests |
/run-integration-tests |
@asddongmen: Your PR was out of date, I have automatically updated it for you. At the same time I will also trigger all tests for you: /run-all-tests If the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes. 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 ti-community-infra/tichi repository. |
What problem does this PR solve?
TiKV GC safe point will be blocked indefinitely due to TiCDC changefeed checkpoint stagnation.
What is changed and how it works?
Set a threshold Y: Regardless of the status of the changefeed, TiCDC is allowed to block TiKV GC safe time for Y hours at most.
The threshold Y is set in the config/config.go file as a variable named gc-TTL and the default value is 84000 seconds (24 hours).
Check List
Tests
Unit test
Manual test (add detailed scripts or steps below)
step1: set
defaultServerConfig.gcTTL = 20
in /pkg/config.gostep2: add
log.Warn("try to update gcSafePoint", zap.Time("gcSafePoint", oracle.GetTimeFromTS(gcSafePoint)))
below line 802 in cdc/owner.go to print log infostep3: In a shell window type
tiup playground
to deploy a tidb cluster.step4: Move to ticdc directory, and type
./bin/cdc server
to to start the cdc component。step5: Type
./cdc cli changefeed create --pd=http://127.0.0.1:2379 --sink-uri="mysql://[email protected]:4000/" --changefeed-id="ttl-test-10"
to create a changefeed.step6: pause above changefeed, you would see gcSafePoint stop update:
step7: gcSafePoint update again after stop 20s:
Code changes
Side effects
Related changes
Release note