Skip to content
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

Race condition preventing successful integration tests #236

Open
glasnt opened this issue Dec 5, 2022 · 0 comments
Open

Race condition preventing successful integration tests #236

glasnt opened this issue Dec 5, 2022 · 0 comments

Comments

@glasnt
Copy link
Collaborator

glasnt commented Dec 5, 2022

There are many tests/ but one of the first ones (hooks-prepostcreate-inline) sees envvars being updated for the service.

The problem is that it appears there can be a time when the old revision is accepting requests, when the new revision should be.

In this example, there is a revision that should return "A" and a revision that should return "AB" (through inline pre- and post-create commands) We should only be testing the service after the deployment is complete, so we should be only ever returning the latest revision ("AB").

But polling the service once a second as it deploys shows there's times when "A" returns to the mix:

Mon Dec  5 04:29:51 UTC 2022
A
Mon Dec  5 04:29:54 UTC 2022
A
Mon Dec  5 04:29:56 UTC 2022
A
Mon Dec  5 04:29:57 UTC 2022
AB
Mon Dec  5 04:29:59 UTC 2022
AB
Mon Dec  5 04:30:00 UTC 2022
A
Mon Dec  5 04:30:01 UTC 2022
AB
Mon Dec  5 04:30:02 UTC 2022
AB

Pending matching against the service logs to establish it was an older revision receiving the request, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant