-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Add locking between replicaGCQueue and multiraft.state.createGroup. #2868
Conversation
I'm not sure how to test this. I've been testing it locally by increasing the iteration count in |
if _, err := rng.rm.GetReplica(desc.RangeID); err == nil { | ||
log.Infof("replica recreated during deletion; aborting deletion") | ||
} | ||
|
||
// TODO(bdarnell): add some sort of locking to prevent the range |
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.
remove?
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.
Done.
What is the similar race? can you document it? |
I'm still working on identifying the similar race. All I know so far is that it produces the same error message as #2815 and it takes over a minute for the test to reproduce it. |
One "similar race" is that I forgot to |
This partially addresses the race seen in cockroachdb#2815. A similar race still occurs but much less frequently.
0e18eb8
to
eed3b7d
Compare
LGTM |
Add locking between replicaGCQueue and multiraft.state.createGroup.
This partially addresses the race seen in #2815. A similar race still
occurs but much less frequently.