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

Do not error in pvc_modifier, when a manual TiKV eviction is requested. #5302

Merged
merged 2 commits into from
Sep 27, 2023

Conversation

anish-db
Copy link
Contributor

@anish-db anish-db commented Sep 25, 2023

What problem does this PR solve?

pvc_modifier keeps throwing errors even if a manual TiKV region leader eviction is requested by annotating the pod per the documentation here:
https://docs.pingcap.com/tidb-in-kubernetes/stable/maintain-a-kubernetes-node#evict-tikv-region-leader

This happens even if no volume modification is actually requested.

What is changed and how does it work?

Do not keep checking if eviction has ended during pvc_modifier sync.
If an annotation does exist for resize, delete it and throw an error once alone to give pod_control.go a chance to stop the eviction. But do not block forever until it is removed as this may have been requested by user manually and should not throw errors.

Code changes

  • Has Go code change
  • Has CI related scripts change

Tests

  • Unit test
  • E2E test
  • Manual test
  • No code

Side effects

  • Breaking backward compatibility
  • Other side effects:

Related changes

  • Need to cherry-pick to the release branch
  • Need to update the documentation

Release Notes

Please refer to Release Notes Language Style Guide before writing the release note.

Fix spurious errors from pvc_modifier when manual TiKV eviction is requested by user annotation

@codecov-commenter
Copy link

Codecov Report

Merging #5302 (1442543) into master (4df3649) will decrease coverage by 0.05%.
The diff coverage is n/a.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5302      +/-   ##
==========================================
- Coverage   57.48%   57.44%   -0.05%     
==========================================
  Files         252      252              
  Lines       30594    30593       -1     
==========================================
- Hits        17586    17573      -13     
- Misses      11271    11278       +7     
- Partials     1737     1742       +5     
Flag Coverage Δ
unittest 57.44% <ø> (-0.05%) ⬇️

@ti-chi-bot
Copy link
Contributor

ti-chi-bot bot commented Sep 27, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: csuzhangxc

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

@ti-chi-bot ti-chi-bot bot removed the lgtm label Sep 27, 2023
@ti-chi-bot
Copy link
Contributor

ti-chi-bot bot commented Sep 27, 2023

[LGTM Timeline notifier]

Timeline:

  • 2023-09-27 06:48:14.096284329 +0000 UTC m=+430283.814626544: ☑️ agreed by csuzhangxc.
  • 2023-09-27 06:48:55.43293563 +0000 UTC m=+430325.151277846: ✖️🔁 reset by ti-chi-bot[bot].

@ti-chi-bot
Copy link
Contributor

ti-chi-bot bot commented Sep 27, 2023

New changes are detected. LGTM label has been removed.

@csuzhangxc csuzhangxc merged commit 3f8c788 into pingcap:master Sep 27, 2023
3 of 4 checks passed
@csuzhangxc
Copy link
Member

/cherry-pick release-1.5

@ti-chi-bot
Copy link
Member

@csuzhangxc: new pull request created to branch release-1.5: #5307.

In response to this:

/cherry-pick release-1.5

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants