Documentation
¶
Overview ¶
Package metrics exposes standardized functions for creating new counters, gauges and histograms. Ideally if we use this package everywhere, we can ensure consistently named metrics.
Index ¶
- func NewCounter(subsystem Subsystem, name, help string, labels ...string) *prometheus.CounterVec
- func NewGauge(subsystem Subsystem, name, help string, labels ...string) *prometheus.GaugeVec
- func NewGaugeWithoutLabels(subsystem Subsystem, name, help string) prometheus.Gauge
- func NewHistogram(subsystem Subsystem, name, help string, buckets []float64, labels ...string) *prometheus.HistogramVec
- type Subsystem
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCounter ¶
func NewCounter(subsystem Subsystem, name, help string, labels ...string) *prometheus.CounterVec
NewCounter will return a prometheus counter object with labels for network and provider.
func NewGauge ¶
func NewGauge(subsystem Subsystem, name, help string, labels ...string) *prometheus.GaugeVec
NewGauge will return a prometheus gauge with labels for network and provider.
func NewGaugeWithoutLabels ¶
func NewGaugeWithoutLabels(subsystem Subsystem, name, help string) prometheus.Gauge
NewGaugeWithoutLabels will return a prometheus gauge without labels.
func NewHistogram ¶
func NewHistogram(subsystem Subsystem, name, help string, buckets []float64, labels ...string) *prometheus.HistogramVec
NewHistogram will return a configured histogram with labels for network and provider.
Types ¶
Click to show internal directories.
Click to hide internal directories.