-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor root device unplug handling
Currently, when the root device is unplugged, we send a TERM signal and immediately ask docker to force remove the device. This is effectively sending a KILL signal since in almost all cases the container does not have enough time to perform graceful cleanup between TERM and force removal, which will send a KILL signal. So we could instead just send a KILL signal directly and wait for exit. With this change, now for all `Detach` and `Stopped` scenario, we know the container is stopped, and since we passed in `--rm` to docker, we know that docker will perform container removal itself. This means that we do not need to explicitly invoke remove anymore and this allows massive cleanup.
- Loading branch information
Showing
5 changed files
with
28 additions
and
145 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters