-
Notifications
You must be signed in to change notification settings - Fork 675
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add sdk gossip handler metrics #1997
Conversation
8b91477
to
bdec28c
Compare
bdec28c
to
26032cf
Compare
@@ -34,20 +36,42 @@ func NewGossiper[T any, U GossipableAny[T]]( | |||
log logging.Logger, | |||
set Set[U], | |||
client *p2p.Client, | |||
) *Gossiper[T, U] { | |||
return &Gossiper[T, U]{ | |||
metrics prometheus.Registerer, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Making sure people are fine w/ this as our signature. Avalanchego's context exposes a MultiGatherer
so we'd be expected to register a prometheus.NewRegistry
into the VM's context to use this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah this function should be taking in a prometheus.Registerer
👍.
Signed-off-by: Joshua Kim <[email protected]>
Why this should be merged
adds metrics to
gossip
packageHow this works
adds metrics
How this was tested
n/a