-
Notifications
You must be signed in to change notification settings - Fork 726
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
mcs: potential data race in scheduling server when pd leader switch #8538
Comments
There is data race between For updateAPIServerMemberLoop, when code reaches to But when the code reaches https://github.com/tikv/pd/blob/1b8fc6a950dbe658a0051c7f8228367b85bc9180/pkg/mcs/scheduling/server/server.go#L196-215, the pd cluster switch leader by For primaryElectionLoop, no leader in etcd made the scheduling primary lose its lease and tried to campaign. For primaryElectionLoop, campaign primary means that it is necessary to start the cluster again, so pd/pkg/mcs/scheduling/server/server.go Line 491 in 1b8fc6a
At the same time, updateAPIServerMemberLoop calls |
|
Bug Report
What did you do?
run ci https://github.com/tikv/pd/actions/runs/10399701689/job/28799000468
What did you expect to see?
no data race
What did you see instead?
What version of PD are you using (
pd-server -V
)?The text was updated successfully, but these errors were encountered: