-
Notifications
You must be signed in to change notification settings - Fork 38.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
Fixing federation secret controller unit test flakiness #36463
Fixing federation secret controller unit test flakiness #36463
Conversation
Adding P1 label for the corresponding label on the issue |
err = WaitForSecretStoreUpdate( | ||
secretController.secretFederatedInformer.GetTargetStore(), | ||
cluster1.Name, types.NamespacedName{Namespace: secret1.Namespace, Name: secret1.Name}.String(), | ||
updatedSecret, wait.ForeverTestTimeout) |
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 guess we could stop this earlier than Forever.
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 will prefer keeping this as is. Dont want to introduce more flakiness because of not enough wait :)
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.
looks like var ForeverTestTimeout = time.Second * 30
so it's not that really forever :)
LGTM if all the tests pass 👍 |
Jenkins unit/integration failed for commit 8ca1b30. Full PR test history. The magic incantation to run this job again is |
@k8s-bot unit test this |
Jenkins GKE smoke e2e failed for commit 8ca1b30. Full PR test history. The magic incantation to run this job again is |
LOL win some lose some :) |
#36351 is tracking the namespace controller failures. @mwielgus and I are debugging it more |
Jenkins GCE e2e failed for commit 8ca1b30. Full PR test history. The magic incantation to run this job again is |
GCE cluster failed to come up with @k8s-bot cvm gce e2e test this |
Adding lgtm as per comment above. unit tests passed |
LGTM to make tests greener, I will try to find more generic fix - other controllers may be affected as well. |
I was unable to reproduce the issue on my laptop (without the fix).
However I agree that there can be a problem in this place. It seems that sometimes we are starting the modify before add is fully completed and as a result the expected modify is in fact another add. I will add a similar fix to other controllers tomorrow as they are equally affected. |
I was running it with |
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
Automatic merge from submit-queue |
Fixes #36422
Adding a wait for the secret to be updated in the store to fix flakiness.
It was failing ~once in 3 to 5 runs before this change. I now have had 30 local runs without a failure.
cc @kubernetes/sig-cluster-federation @mwielgus
This change is![Reviewable](https://camo.githubusercontent.com/2d899f4291d07d3cd2fa4aaae1e3b243f164c23fce87d30a589ace0d496a444c/68747470733a2f2f72657669657761626c652e6b756265726e657465732e696f2f7265766965775f627574746f6e2e737667)