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

server: prevent misoperation when there are tiflash nodes (#2242) #2254

Merged
merged 2 commits into from
Mar 17, 2020

Conversation

sre-bot
Copy link
Contributor

@sre-bot sre-bot commented Mar 17, 2020

cherry-pick #2242 to release-3.1


Signed-off-by: disksing [email protected]

What problem does this PR solve?

Fix #2237

What is changed and how it works?

  • When placement rules not enabled, don't allow add tiflash node.
  • When the cluster has tiFlash nodes, don't allow disable placement rules.

Check List

Tests

  • Unit test

Related changes

  • Need to cherry-pick to the release branch

@codecov-io
Copy link

Codecov Report

Merging #2254 into release-3.1 will increase coverage by 0.14%.
The diff coverage is 89.47%.

Impacted file tree graph

@@               Coverage Diff               @@
##           release-3.1    #2254      +/-   ##
===============================================
+ Coverage        74.89%   75.04%   +0.14%     
===============================================
  Files              196      196              
  Lines            20152    20164      +12     
===============================================
+ Hits             15093    15132      +39     
+ Misses            3907     3889      -18     
+ Partials          1152     1143       -9
Impacted Files Coverage Δ
server/grpc_service.go 58.11% <100%> (+1.89%) ⬆️
server/util.go 54.73% <100%> (+2.51%) ⬆️
server/server.go 65.29% <77.77%> (+1.39%) ⬆️
server/member/leader.go 78.57% <0%> (-1.03%) ⬇️
server/region_syncer/client.go 78.44% <0%> (-0.87%) ⬇️
server/handler.go 51.18% <0%> (-0.44%) ⬇️
server/cluster/cluster.go 80.82% <0%> (-0.35%) ⬇️
server/config/option.go 88.31% <0%> (+0.86%) ⬆️
server/core/storage.go 73.73% <0%> (+1.01%) ⬆️
server/schedulers/adjacent_region.go 76.47% <0%> (+1.06%) ⬆️
... and 7 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 1206736...90fa265. Read the comment docs.

@rleungx
Copy link
Member

rleungx commented Mar 17, 2020

/run-all-tests

@nolouch nolouch merged commit bdbbf2a into tikv:release-3.1 Mar 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants