-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
bug: Race condition when setting application destination inferred server or name #21182
Comments
I'd recommend that we revert the change until the race condition is fixed. I'm seeing ~2/3 test runs fail, and that's going to be a drag on PR velocity until the bug is fixed. |
I would like to propose to temporary disable that particular test instead since the race condition will still be there even after reverting the PR (It will be just masked as there will be no tests to validate it). |
How can we be confident that the changes haven't make the race condition worse? |
Indeed, the race condition might be worse now since it might trigger on both I've just raised #21201 btw. I hope it addresses the race condition. |
Unfortunately that PR didn't solve it 😞 . The race being so nondeterministic I thought it will be addressing it after running it many times locally without any failures 😄 . |
I'm curious if a radical refactor could eliminate the problem entirely: #21189 I'm not sure I like the approach yet, but I think it's worth looking at. |
I like that approach, it would simplify a lot the logic in many areas and also will most probably reduce if not eliminates existing related bugs and race conditions. Meanwhile I've raised an alternative PR to this one to temporary avoid running the test when |
Checklist:
argocd version
.Describe the bug
Once #21063 was merged, a race condition was surfaced when trying to set the application destination inferred server or name.
To Reproduce
testApp
(https://github.com/argoproj/argo-cd/blob/master/server/application/application_test.go#L2264 fromtestApp := newTestApp
totestApp := newTestAppWithDestName
go test -race -run TestMaxPodLogsRender ./server/application -count=1
This race condition is not always popping up. Since it is intermittently triggered, you might need to run the test few times in order to hit the race condition
Expected behaviour
No race conditions should occur.
Screenshots
None
Version
master
branchLogs
The text was updated successfully, but these errors were encountered: