package
0.3.13-beta.0
Repository: https://github.com/spacemeshos/go-spacemesh.git
Documentation: pkg.go.dev
# Functions
NewCounter creates a Counter metrics under the global namespace returns nop if metrics are disabled.
NewGauge creates a Gauge metrics under the global namespace returns nop if metrics are disabled.
NewHistogram creates a Histogram metrics under the global namespace returns nop if metrics are disabled.
NewHistogramWithBuckets creates a Histogram metrics with custom buckets.
ReportMessageLatency records the latency for the given protocol and message type, if the protocol consists only of a single message then the protocol should be provided as the message type.
StartMetricsServer begins listening and supplying metrics on localhost:`metricsPort`/metrics.
StartPushingMetrics begins pushing metrics to the url specified by the --metrics-push flag with period specified by the --metrics-push-period flag.
# Constants
Namespace is the basic namespace where all metrics are defined under.