Skip to content
This repository has been archived by the owner on Dec 7, 2023. It is now read-only.

Avoid race between stop/kill and wait #773

Merged
merged 3 commits into from
Jan 18, 2021
Merged

Avoid race between stop/kill and wait #773

merged 3 commits into from
Jan 18, 2021

Conversation

bboreham
Copy link
Contributor

Depending on how fast Docker actions the auto-remove on container death, the wait can fail with "No such container".
Code adapted from RemoveContainer() which already had this fix.

Also make clear that such an error comes from waiting for container.

Fixes #679, #658

Code adapted from RemoveContainer() which already had this fix.
Now the underlying problem is fixed.
Copy link
Contributor

@darkowlzz darkowlzz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will solve most of the docker related flaky tests we have.
Very nice solution. Thanks.
LGTM!

@bboreham bboreham merged commit 4370435 into master Jan 18, 2021
@bboreham bboreham deleted the wait-before-stop branch January 18, 2021 17:07
@stealthybox
Copy link
Contributor

Very nice patch -- thanks for catching this @bboreham

@stealthybox stealthybox added area/runtime Issues related to container runtimes kind/bug Categorizes issue or PR as related to a bug. labels Feb 2, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area/runtime Issues related to container runtimes kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

flaky volume e2e test when using docker + CNI
3 participants