Skip to content
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

log backup: fix the issue that paused service safepoint not removed #52106

Merged
merged 4 commits into from
Mar 29, 2024

Conversation

3pointer
Copy link
Contributor

@3pointer 3pointer commented Mar 26, 2024

What problem does this PR solve?

Issue Number: close #52082

Problem Summary:
stop task didn't remove service safepoint correctly.

What changed and how does it work?

  1. set ttl == 0 to make pd service remove this safepoint.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No need to test
    • I checked and no code files have been changed.

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

Please refer to Release Notes Language Style Guide to write a quality release note.

Fix the issue that stop log backup didn't clean paused task gc safepoint correctly.

Copy link

ti-chi-bot bot commented Mar 26, 2024

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@ti-chi-bot ti-chi-bot bot added do-not-merge/needs-triage-completed do-not-merge/needs-tests-checked do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. release-note-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Mar 26, 2024
Copy link

tiprow bot commented Mar 26, 2024

Hi @3pointer. Thanks for your PR.

PRs from untrusted users cannot be marked as trusted with /ok-to-test in this repo meaning untrusted PR authors can never trigger tests themselves. Collaborators can still trigger tests on the PR using /test all.

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.

@3pointer 3pointer marked this pull request as ready for review March 27, 2024 09:01
@ti-chi-bot ti-chi-bot bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. do-not-merge/needs-tests-checked release-note-none Denotes a PR that doesn't merit a release note. labels Mar 27, 2024
@ti-chi-bot ti-chi-bot bot added approved needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Mar 27, 2024
@@ -724,8 +725,8 @@ func RunStreamStop(
if err := streamMgr.setGCSafePoint(ctx,
utils.BRServiceSafePoint{
ID: buildPauseSafePointName(ti.Info.Name),
TTL: utils.DefaultStreamStartSafePointTTL,
BackupTS: 0,
TTL: 0, // 0 means remove this service safe point.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I recall right we remove the safepoint by setting the ts to zero before. Will set TTL to zero work?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, and if set ts to 0. it won't pass the check before connect to pd to remove this safepoint.

@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Mar 28, 2024
Copy link

ti-chi-bot bot commented Mar 28, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-03-27 09:35:21.887202733 +0000 UTC m=+2060548.909449118: ☑️ agreed by YuJuncen.
  • 2024-03-28 08:01:51.550013676 +0000 UTC m=+2141338.572260064: ☑️ agreed by Leavrth.

Copy link

codecov bot commented Mar 28, 2024

Codecov Report

Merging #52106 (2c94cb0) into master (422ae46) will increase coverage by 0.4279%.
Report is 3 commits behind head on master.
The diff coverage is 0.0000%.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #52106        +/-   ##
================================================
+ Coverage   72.4123%   72.8402%   +0.4279%     
================================================
  Files          1490       1499         +9     
  Lines        366232     441359     +75127     
================================================
+ Hits         265197     321487     +56290     
- Misses        81461      99689     +18228     
- Partials      19574      20183       +609     
Flag Coverage Δ
integration 48.8941% <0.0000%> (?)
unit 70.5510% <0.0000%> (-1.7512%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
dumpling 53.9957% <ø> (-2.3014%) ⬇️
parser ∅ <ø> (∅)
br 51.4204% <0.0000%> (+5.1215%) ⬆️

Copy link

ti-chi-bot bot commented Mar 29, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: BornChanger, Leavrth, YuJuncen

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@BornChanger
Copy link
Contributor

/retest

Copy link

tiprow bot commented Mar 29, 2024

@BornChanger: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

@3pointer
Copy link
Contributor Author

/retest

Copy link

tiprow bot commented Mar 29, 2024

@3pointer: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

@3pointer
Copy link
Contributor Author

/ok-to-test

@ti-chi-bot ti-chi-bot bot added the ok-to-test Indicates a PR is ready to be tested. label Mar 29, 2024
@ti-chi-bot ti-chi-bot bot merged commit 8bba826 into pingcap:master Mar 29, 2024
29 of 30 checks passed
@3pointer 3pointer added needs-cherry-pick-release-6.5 Should cherry pick this PR to release-6.5 branch. needs-cherry-pick-release-7.1 Should cherry pick this PR to release-7.1 branch. needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. labels Mar 29, 2024
@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-7.1: #52248.

ti-chi-bot pushed a commit to ti-chi-bot/tidb that referenced this pull request Mar 29, 2024
@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-6.5: #52249.

@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-7.5: #52250.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm needs-cherry-pick-release-6.5 Should cherry pick this PR to release-6.5 branch. needs-cherry-pick-release-7.1 Should cherry pick this PR to release-7.1 branch. needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. ok-to-test Indicates a PR is ready to be tested. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

GC safepoint not moving forward after log backup stopped
5 participants