cherry-pick: all: opt log levels
Updates #3929. Squashed commit of the following: commit bfb2361d81a0667c36193484ca125d08e5638b21 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Fri Dec 24 17:23:39 2021 +0300 all: opt log levels
This commit is contained in:
parent
7528699fc2
commit
9f36e57c1e
|
@ -298,7 +298,11 @@ func shutdownSrv(ctx context.Context, srv *http.Server) {
|
|||
|
||||
err := srv.Shutdown(ctx)
|
||||
if err != nil {
|
||||
log.Error("error while shutting down http server %q: %s", srv.Addr, err)
|
||||
if errors.Is(err, context.Canceled) {
|
||||
log.Debug("shutting down http server %q: %s", srv.Addr, err)
|
||||
} else {
|
||||
log.Error("shutting down http server %q: %s", srv.Addr, err)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue