Skip to content

Commit f2b9d02

Browse files
committed
Downgrade "error dialing peer" log to debug
In production we see a lot of these messages. Failing to dial a peer is usually because the peer is unreachable which is not an error, so logging it as an error is misleading.
1 parent 925a119 commit f2b9d02

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

rolling-shutter/p2p/dht.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,10 @@ func findPeers(ctx context.Context, h host.Host, d discovery.Discoverer, ns stri
9393
if h.Network().Connectedness(p.ID) != network.Connected {
9494
_, err = h.Network().DialPeer(ctx, p.ID)
9595
if err != nil {
96-
log.Error().Err(err).Str("peer", p.ID.String()).Msg("error dialing peer")
96+
log.Debug().
97+
Err(err).
98+
Str("peer", p.ID.String()).
99+
Msg("error dialing peer")
97100
failedDials++
98101
}
99102
newConnections++

0 commit comments

Comments
 (0)