Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Metrics ¶
type Metrics struct {
TMIMsgsCount Observer
TMICommandCount Observer
LearnedCount Observer
ForgotCount Observer
SpeakLatency Observer
LearnLatency Observer
UsedMessagesForGeneration Observer
TMISendWait Observer
}
func (Metrics) Collectors ¶
func (m Metrics) Collectors() []prometheus.Collector
type Observer ¶
type Observer interface {
Observe(val float64, labels ...string)
// for now we will tightly couple to the prometheus collector type
// the go otel metrics sdk also has a prometheus adapter that implements this interface.
prometheus.Collector
}
func NewPromCounter ¶
func NewPromCounter(m prometheus.Counter) Observer
func NewPromGauge ¶
func NewPromGauge(m prometheus.Counter) Observer
func NewPromHistogram ¶
func NewPromHistogram(m prometheus.Histogram) Observer
func NewPromObserverVec ¶
func NewPromObserverVec(m prometheus.ObserverVec) Observer
for histogram or summary vecs
type PrometheusMetric ¶
type PrometheusMetric struct {
prometheus.Collector
// contains filtered or unexported fields
}
func (*PrometheusMetric) Observe ¶
func (m *PrometheusMetric) Observe(val float64, labels ...string)
Click to show internal directories.
Click to hide internal directories.