From 46cd974e2a5cda25032e44c525a164a0989ee061 Mon Sep 17 00:00:00 2001 From: Ainar Garipov Date: Fri, 24 Dec 2021 17:29:57 +0300 Subject: [PATCH] Pull request: all: opt log levels Updates #3929. Squashed commit of the following: commit bfb2361d81a0667c36193484ca125d08e5638b21 Author: Ainar Garipov Date: Fri Dec 24 17:23:39 2021 +0300 all: opt log levels --- go.mod | 2 +- go.sum | 4 ++-- internal/home/controlinstall.go | 6 +++++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/go.mod b/go.mod index c63fbe4d..0988e3a4 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module github.com/AdguardTeam/AdGuardHome go 1.17 require ( - github.com/AdguardTeam/dnsproxy v0.40.0 + github.com/AdguardTeam/dnsproxy v0.40.1 github.com/AdguardTeam/golibs v0.10.3 github.com/AdguardTeam/urlfilter v0.15.1 github.com/NYTimes/gziphandler v1.1.1 diff --git a/go.sum b/go.sum index 8ae55223..0ee66fd4 100644 --- a/go.sum +++ b/go.sum @@ -7,8 +7,8 @@ dmitri.shuralyov.com/html/belt v0.0.0-20180602232347-f7d459c86be0/go.mod h1:JLBr dmitri.shuralyov.com/service/change v0.0.0-20181023043359-a85b471d5412/go.mod h1:a1inKt/atXimZ4Mv927x+r7UpyzRUf4emIoiiSC2TN4= dmitri.shuralyov.com/state v0.0.0-20180228185332-28bcc343414c/go.mod h1:0PRwlb0D6DFvNNtx+9ybjezNCa8XF0xaYcETyp6rHWU= git.apache.org/thrift.git v0.0.0-20180902110319-2566ecd5d999/go.mod h1:fPE2ZNJGynbRyZ4dJvy6G277gSllfV2HJqblrnkyeyg= -github.com/AdguardTeam/dnsproxy v0.40.0 h1:4JeOCG7aOEQxXhvAZwI7VknuHjXYJlwehO5ufkkrJaQ= -github.com/AdguardTeam/dnsproxy v0.40.0/go.mod h1:PZ9l22h3Er+5mxFQB7oHZMTvx+aa9R6LbzA/ikXQlS0= +github.com/AdguardTeam/dnsproxy v0.40.1 h1:lYNi7VeCBhmdyf5xEUxfj84ikgiz5cjzocL9moiIRhk= +github.com/AdguardTeam/dnsproxy v0.40.1/go.mod h1:PZ9l22h3Er+5mxFQB7oHZMTvx+aa9R6LbzA/ikXQlS0= github.com/AdguardTeam/golibs v0.4.0/go.mod h1:skKsDKIBB7kkFflLJBpfGX+G8QFTx0WKUzB6TIgtUj4= github.com/AdguardTeam/golibs v0.4.2/go.mod h1:skKsDKIBB7kkFflLJBpfGX+G8QFTx0WKUzB6TIgtUj4= github.com/AdguardTeam/golibs v0.9.2/go.mod h1:fCAMwPBJ8S7YMYbTWvYS+eeTLblP5E04IDtNAo7y7IY= diff --git a/internal/home/controlinstall.go b/internal/home/controlinstall.go index baae5d00..8baa3f6a 100644 --- a/internal/home/controlinstall.go +++ b/internal/home/controlinstall.go @@ -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) + } } }