mirror of
https://github.com/containers/podman.git
synced 2025-08-06 11:32:07 +08:00
Up time between checks for podman wait
Prior to this patch, we were polling continuously to check if a container had died. This patch changes this to poll 10 times a second, which should be more than sufficient and drastically reduce CPU utilization. Signed-off-by: Matthew Heon <matthew.heon@gmail.com>
This commit is contained in:
@ -597,7 +597,7 @@ func (c *Container) Wait() (int32, error) {
|
||||
return -1, ErrCtrRemoved
|
||||
}
|
||||
|
||||
err := wait.PollImmediateInfinite(1,
|
||||
err := wait.PollImmediateInfinite(100*time.Millisecond,
|
||||
func() (bool, error) {
|
||||
stopped, err := c.isStopped()
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user