-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
store/tikv: pipe the split and scatter task #23357
Conversation
Signed-off-by: nolouch <[email protected]>
[REVIEW NOTIFICATION] This pull request has not been approved. To complete the pull request process, please ask the reviewers in the list to review by filling The full list of commands accepted by this bot can be found here. Reviewer can indicate their review by writing |
store/tikv/split_region.go
Outdated
for _, r := range spResp.Regions { | ||
tid := int64(0) | ||
if tableID != nil { | ||
tid = *tableID | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for _, r := range spResp.Regions { | |
tid := int64(0) | |
if tableID != nil { | |
tid = *tableID | |
} | |
tid := int64(0) | |
if tableID != nil { | |
tid = *tableID | |
} | |
for _, r := range spResp.Regions { |
store/tikv/split_region.go
Outdated
tid := int64(0) | ||
if tableID != nil { | ||
tid = *tableID | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tid := int64(0) | |
if tableID != nil { | |
tid = *tableID | |
} |
Signed-off-by: nolouch <[email protected]>
Signed-off-by: nolouch <[email protected]>
tid = *tableID | ||
} | ||
spResp := batchResp.resp.Resp.(*kvrpcpb.SplitRegionResponse) | ||
for _, r := range spResp.Regions { | ||
if err = s.scatterRegion(bo, r.Id, tableID); err == nil { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So it's still using
tidb/store/tikv/split_region.go
Line 217 in 579421f
_, err := s.pdClient.ScatterRegions(bo.ctx, []uint64{regionID}, opts...) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I mean #22788 .
OK, I'm off topic.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The current region scatter may not work in a specific case which described in tikv/pd#3422 , I think it's not related to the api.
@nolouch: PR needs rebase. 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. |
Signed-off-by: nolouch [email protected]
What problem does this PR solve?
close #22969
Problem Summary:
Splitting and Scattering at the same time will cause multiple conflicts on the same region.
What is changed and how it works?
pipeline all splits task and scatter tasks
Release note
split table
more stable