From 0e2a3f0a7ed1730b0598425cea93783f8081c812 Mon Sep 17 00:00:00 2001 From: Dan Laine Date: Thu, 27 Aug 2020 15:42:49 -0400 Subject: [PATCH 1/2] lower log level --- snow/networking/router/handler.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/snow/networking/router/handler.go b/snow/networking/router/handler.go index 2ccc397f1354..0d17b8340835 100644 --- a/snow/networking/router/handler.go +++ b/snow/networking/router/handler.go @@ -8,6 +8,8 @@ import ( "sync" "time" + "github.com/ava-labs/gecko/utils/constants" + "github.com/prometheus/client_golang/prometheus" "github.com/ava-labs/gecko/ids" @@ -235,7 +237,12 @@ func (h *Handler) dispatchMsg(msg message) { h.ctx.Lock.Lock() defer h.ctx.Lock.Unlock() - h.ctx.Log.Debug("Forwarding message to consensus: %s", msg) + if msg.requestID != constants.GossipMsgRequestID { + h.ctx.Log.Debug("Forwarding message to consensus: %s", msg) + } else { + h.ctx.Log.Verbo("Forwarding message to consensus: %s", msg) + } + var ( err error ) From 998f2b439d2288619b2cb25abd9ce9d5f8470995 Mon Sep 17 00:00:00 2001 From: StephenButtolph Date: Sun, 30 Aug 2020 04:32:51 -0400 Subject: [PATCH 2/2] minor cleanup --- snow/networking/router/handler.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/snow/networking/router/handler.go b/snow/networking/router/handler.go index 0d17b8340835..3558110f6c6e 100644 --- a/snow/networking/router/handler.go +++ b/snow/networking/router/handler.go @@ -8,18 +8,19 @@ import ( "sync" "time" - "github.com/ava-labs/gecko/utils/constants" - "github.com/prometheus/client_golang/prometheus" "github.com/ava-labs/gecko/ids" "github.com/ava-labs/gecko/snow" "github.com/ava-labs/gecko/snow/engine/common" "github.com/ava-labs/gecko/snow/validators" + "github.com/ava-labs/gecko/utils/constants" "github.com/ava-labs/gecko/utils/timer" ) const ( + // DefaultStakerPortion defines the default percentage of resources to + // allocate to stakers. DefaultStakerPortion float64 = 0.2 )