-
Notifications
You must be signed in to change notification settings - Fork 9.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
[Problematic new solution] Fix race condition (also a regression of the PR 19139) #19256
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ahrtr The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
… the errc Also added commment to clarify the etcd shutting down workflow Signed-off-by: Benjamin Wang <[email protected]>
0517c82
to
d12c2cc
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files
... and 12 files with indirect coverage changes @@ Coverage Diff @@
## main #19256 +/- ##
==========================================
- Coverage 68.85% 68.80% -0.05%
==========================================
Files 420 420
Lines 35655 35675 +20
==========================================
- Hits 24551 24547 -4
- Misses 9683 9705 +22
- Partials 1421 1423 +2 Continue to review full report in Codecov by Sentry.
|
@ahrtr: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. 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-sigs/prow repository. I understand the commands that are listed here. |
But |
It should be not correct. We have two correct solutions:
|
Not sure I understand, are you saying that the following code is not concurrency safe? |
You are right. It's safe both in your example and this PR. Calling But I still prefer #19257 to this one.
|
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-sigs/prow repository. |
Fix #19172
Note this solution has a potential race condition, because the grandson routine (created in serve ) call
wg.Add(1)
async, so it may happen afterwg.Wait()
.Original solution: #19221
cc @serathius @fuweid