Skip to content

Commit

Permalink
Use zap.Stringer rather than zap.Any (#2320)
Browse files Browse the repository at this point in the history
  • Loading branch information
StephenButtolph authored Nov 15, 2023
1 parent 44f3aba commit dcc6ea8
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions snow/networking/handler/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -455,7 +455,7 @@ func (h *handler) handleSyncMsg(ctx context.Context, msg Message) error {
h.ctx.Log.Verbo("forwarding sync message to consensus",
zap.Stringer("nodeID", nodeID),
zap.Stringer("messageOp", op),
zap.Any("message", body),
zap.Stringer("message", body),
)
} else {
h.ctx.Log.Debug("forwarding sync message to consensus",
Expand Down Expand Up @@ -488,7 +488,7 @@ func (h *handler) handleSyncMsg(ctx context.Context, msg Message) error {
zap.Duration("msgHandlingTime", msgHandlingTime),
zap.Stringer("nodeID", nodeID),
zap.Stringer("messageOp", op),
zap.Any("message", body),
zap.Stringer("message", body),
)
}
}()
Expand Down Expand Up @@ -793,7 +793,7 @@ func (h *handler) executeAsyncMsg(ctx context.Context, msg Message) error {
h.ctx.Log.Verbo("forwarding async message to consensus",
zap.Stringer("nodeID", nodeID),
zap.Stringer("messageOp", op),
zap.Any("message", body),
zap.Stringer("message", body),
)
} else {
h.ctx.Log.Debug("forwarding async message to consensus",
Expand Down Expand Up @@ -893,7 +893,7 @@ func (h *handler) handleChanMsg(msg message.InboundMessage) error {
if h.ctx.Log.Enabled(logging.Verbo) {
h.ctx.Log.Verbo("forwarding chan message to consensus",
zap.Stringer("messageOp", op),
zap.Any("message", body),
zap.Stringer("message", body),
)
} else {
h.ctx.Log.Debug("forwarding chan message to consensus",
Expand Down Expand Up @@ -922,7 +922,7 @@ func (h *handler) handleChanMsg(msg message.InboundMessage) error {
zap.Duration("processingTime", processingTime),
zap.Duration("msgHandlingTime", msgHandlingTime),
zap.Stringer("messageOp", op),
zap.Any("message", body),
zap.Stringer("message", body),
)
}
}()
Expand Down

0 comments on commit dcc6ea8

Please sign in to comment.