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

core: allow cancel load region (#4175) #4217

Merged
merged 10 commits into from
Nov 30, 2021

Conversation

ti-chi-bot
Copy link
Member

This is an automated cherry-pick of #4175

What problem does this PR solve?

Fix #3936

What is changed and how it works?

  • add cancel support for core.LoadRegion functions
  • replace chan bool with contextes in region syncer client
  • add test case

Check List

Tests

  • Unit test

Release note

Fix the issue that PD may not elect leader as soon as leader step down

disksing and others added 8 commits October 19, 2021 05:57
Signed-off-by: disksing <i@disksing.com>
Signed-off-by: disksing <i@disksing.com>
Signed-off-by: disksing <i@disksing.com>
Signed-off-by: disksing <i@disksing.com>
This reverts commit 5b69c4a.

Signed-off-by: disksing <i@disksing.com>
Signed-off-by: disksing <i@disksing.com>
Signed-off-by: HunDunDM <hundundm@gmail.com>
Signed-off-by: disksing <i@disksing.com>

Co-authored-by: Ryan Leung <rleungx@gmail.com>
@ti-chi-bot
Copy link
Member Author

ti-chi-bot commented Oct 19, 2021

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • nolouch

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

The full list of commands accepted by this bot can be found here.

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. do-not-merge/cherry-pick-not-approved type/bugfix This PR fixes a bug. type/cherry-pick-for-release-5.1 The PR belongs to release-5.1 cherry pick. labels Oct 19, 2021
@codecov
Copy link

codecov bot commented Oct 19, 2021

Codecov Report

Merging #4217 (8b5ef1b) into release-5.1 (32885c6) will decrease coverage by 0.27%.
The diff coverage is 89.65%.

Impacted file tree graph

@@               Coverage Diff               @@
##           release-5.1    #4217      +/-   ##
===============================================
- Coverage        75.41%   75.13%   -0.28%     
===============================================
  Files              245      245              
  Lines            24718    24710       -8     
===============================================
- Hits             18642    18567      -75     
- Misses            4471     4515      +44     
- Partials          1605     1628      +23     
Flag Coverage Δ
unittests 75.13% <89.65%> (-0.28%) ⬇️

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

Impacted Files Coverage Δ
server/cluster/cluster.go 82.39% <0.00%> (-0.38%) ⬇️
server/region_syncer/server.go 82.96% <ø> (-6.01%) ⬇️
server/core/storage.go 68.44% <75.00%> (-0.77%) ⬇️
server/region_syncer/client.go 79.68% <94.11%> (-2.01%) ⬇️
server/core/region_storage.go 77.65% <100.00%> (+1.79%) ⬆️
server/member/member.go 67.20% <0.00%> (-5.92%) ⬇️
server/id/id.go 76.19% <0.00%> (-4.77%) ⬇️
pkg/dashboard/adapter/manager.go 78.72% <0.00%> (-4.26%) ⬇️
server/tso/allocator_manager.go 77.46% <0.00%> (-3.01%) ⬇️
... and 11 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 32885c6...8b5ef1b. Read the comment docs.

@zhouqiang-cl zhouqiang-cl added the cherry-pick-approved Cherry pick PR approved by release team. label Nov 30, 2021
Copy link
Contributor

@nolouch nolouch left a comment

Choose a reason for hiding this comment

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

lgtm

@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label Nov 30, 2021
@ti-chi-bot
Copy link
Member Author

[FORMAT CHECKER NOTIFICATION]

Please provide the associated issue number in the commit messages, for example: close #12345, or ref #12345.

@disksing disksing added the require-LGT1 Indicates that the PR requires an LGTM. label Nov 30, 2021
@disksing
Copy link
Contributor

/merge

@ti-chi-bot
Copy link
Member Author

@disksing: It seems you want to merge this PR, I will help you trigger all the tests:

/run-all-tests

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.

@ti-chi-bot
Copy link
Member Author

This pull request has been accepted and is ready to merge.

Commit hash: 8b5ef1b

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Nov 30, 2021
@disksing
Copy link
Contributor

/run-all-tests

@disksing disksing merged commit 9615a4a into tikv:release-5.1 Nov 30, 2021
@zhouqiang-cl zhouqiang-cl added this to the v5.1.4 milestone Feb 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cherry-pick-approved Cherry pick PR approved by release team. do-not-merge/invalid-commit-message release-note Denotes a PR that will be considered when it comes time to generate release notes. require-LGT1 Indicates that the PR requires an LGTM. status/can-merge Indicates a PR has been approved by a committer. status/LGT1 Indicates that a PR has LGTM 1. triage/accept type/bugfix This PR fixes a bug. type/cherry-pick-for-release-5.1 The PR belongs to release-5.1 cherry pick.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants