feat(log): change unhealthy log to debug level

This commit is contained in:
Quentin McGaw
2024-02-21 16:44:35 +00:00
parent 423a5c37e0
commit 0eed558b10
2 changed files with 2 additions and 1 deletions

View File

@@ -29,7 +29,7 @@ func (s *Server) runHealthcheckLoop(ctx context.Context, done chan<- struct{}) {
s.vpn.healthyTimer.Stop() s.vpn.healthyTimer.Stop()
s.vpn.healthyWait = *s.config.VPN.Initial s.vpn.healthyWait = *s.config.VPN.Initial
} else if previousErr == nil && err != nil { } else if previousErr == nil && err != nil {
s.logger.Info("unhealthy: " + err.Error()) s.logger.Debug("unhealthy: " + err.Error())
s.vpn.healthyTimer.Stop() s.vpn.healthyTimer.Stop()
s.vpn.healthyTimer = time.NewTimer(s.vpn.healthyWait) s.vpn.healthyTimer = time.NewTimer(s.vpn.healthyWait)
} }

View File

@@ -1,6 +1,7 @@
package healthcheck package healthcheck
type Logger interface { type Logger interface {
Debug(s string)
Info(s string) Info(s string)
Error(s string) Error(s string)
} }