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

region_sync: region syncer support bucket #4750

Merged
merged 5 commits into from
Apr 14, 2022

Conversation

bufferflies
Copy link
Contributor

What problem does this PR solve?

Issue Number: Close #4749
depences: #4670

What is changed and how it works?

Check List

Tests

  • Unit test

Code changes

  • Has persistent data change

Side effects

Related changes

Release note

 None.

@ti-chi-bot
Copy link
Member

ti-chi-bot commented Mar 17, 2022

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • JmPotato
  • lhy1024

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 the release-note-none Denotes a PR that doesn't merit a release note. label Mar 17, 2022
@codecov
Copy link

codecov bot commented Mar 17, 2022

Codecov Report

Merging #4750 (2f4f254) into master (07a6bcd) will increase coverage by 0.04%.
The diff coverage is 89.47%.

@@            Coverage Diff             @@
##           master    #4750      +/-   ##
==========================================
+ Coverage   75.38%   75.42%   +0.04%     
==========================================
  Files         295      295              
  Lines       28696    28715      +19     
==========================================
+ Hits        21633    21659      +26     
+ Misses       5151     5145       -6     
+ Partials     1912     1911       -1     
Flag Coverage Δ
unittests 75.42% <89.47%> (+0.04%) ⬆️

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

Impacted Files Coverage Δ
server/region_syncer/server.go 85.54% <86.66%> (+0.11%) ⬆️
server/region_syncer/client.go 85.60% <100.00%> (+0.44%) ⬆️
server/election/leadership.go 73.19% <0.00%> (-4.13%) ⬇️
server/tso/tso.go 64.00% <0.00%> (-4.00%) ⬇️
pkg/dashboard/adapter/manager.go 79.78% <0.00%> (-3.20%) ⬇️
server/member/member.go 63.68% <0.00%> (-2.11%) ⬇️
server/election/lease.go 86.15% <0.00%> (-1.54%) ⬇️
tools/pd-ctl/pdctl/command/operator.go 66.66% <0.00%> (-1.15%) ⬇️
server/handler.go 52.82% <0.00%> (-0.39%) ⬇️
server/cluster/coordinator.go 75.23% <0.00%> (-0.24%) ⬇️
... and 13 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 07a6bcd...2f4f254. Read the comment docs.

server/cluster/cluster.go Outdated Show resolved Hide resolved
server/cluster/cluster.go Outdated Show resolved Hide resolved
server/cluster/cluster.go Outdated Show resolved Hide resolved
@ti-chi-bot ti-chi-bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 30, 2022
Signed-off-by: bufferflies <1045931706@qq.com>
@bufferflies
Copy link
Contributor Author

reopen

@bufferflies bufferflies reopened this Apr 12, 2022
@bufferflies
Copy link
Contributor Author

PTAL @JmPotato

Copy link
Member

@JmPotato JmPotato left a comment

Choose a reason for hiding this comment

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

LGTM. Please fix the check.

@ti-chi-bot ti-chi-bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Apr 12, 2022
Signed-off-by: bufferflies <1045931706@qq.com>
@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label Apr 14, 2022
regionLeaders := resp.GetRegionLeaders()
hasStats := len(stats) == len(regions)
hasBuckets := len(buckets) == len(regions)
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it possible to have more than one bucket in a region?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It is impossible, one region has only one buckets properties include many buckets.

@ti-chi-bot ti-chi-bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Apr 14, 2022
@JmPotato
Copy link
Member

/merge

@ti-chi-bot
Copy link
Member

@JmPotato: 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

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

Commit hash: 2f4f254

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Apr 14, 2022
@ti-chi-bot ti-chi-bot merged commit 4f9369f into tikv:master Apr 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-note-none Denotes a PR that doesn't merit a release note. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

region syncer should support buckets
4 participants