From: Tom Clegg Date: Thu, 30 Jun 2022 03:59:37 +0000 (-0400) Subject: 16552: boot: wait for child proc cleanup when shutting down. X-Git-Tag: 2.5.0~116^2~27 X-Git-Url: https://git.arvados.org/arvados.git/commitdiff_plain/f1b67a590f30b5f8824b14f7b49520106a13bb29 16552: boot: wait for child proc cleanup when shutting down. Arvados-DCO-1.1-Signed-off-by: Tom Clegg --- diff --git a/lib/boot/supervisor.go b/lib/boot/supervisor.go index 8eb375b874..52cd0b1616 100644 --- a/lib/boot/supervisor.go +++ b/lib/boot/supervisor.go @@ -471,6 +471,7 @@ func (super *Supervisor) WaitReady() bool { super.logger.Infof("waiting for %s to be ready", id) if !super2.WaitReady() { super.logger.Infof("%s startup failed", id) + super.Stop() return false } super.logger.Infof("%s is ready", id) @@ -484,6 +485,7 @@ func (super *Supervisor) WaitReady() bool { select { case <-ticker.C: case <-super.ctx.Done(): + super.Stop() return false } if super.healthChecker == nil {