Versions in this module Expand all Collapse all v1 v1.0.0 Dec 16, 2023 Changes in this version + func DurationToString(duration time.Duration) string + func SanitizeMetricName(name string) string + type Scope interface + CurrentScope func() string + MustNewCounter func(name, description string) prometheus.Counter + MustNewCounterVec func(name, description string, labelNames ...string) *prometheus.CounterVec + MustNewGauge func(name, description string) prometheus.Gauge + MustNewGaugeVec func(name, description string, labelNames ...string) *prometheus.GaugeVec + MustNewHistogram func(name, description string) prometheus.Histogram + MustNewHistogramVec func(name, description string, labelNames ...string) *prometheus.HistogramVec + MustNewStopWatch func(name, description string, scale time.Duration) StopWatch + MustNewStopWatchVec func(name, description string, scale time.Duration, labelNames ...string) *StopWatchVec + MustNewSummary func(name, description string) prometheus.Summary + MustNewSummaryVec func(name, description string, labelNames ...string) *prometheus.SummaryVec + MustNewSummaryWithOptions func(name, description string, options SummaryOptions) prometheus.Summary + NewCounter func(name, description string) (prometheus.Counter, error) + NewCounterVec func(name, description string, labelNames ...string) (*prometheus.CounterVec, error) + NewGauge func(name, description string) (prometheus.Gauge, error) + NewGaugeVec func(name, description string, labelNames ...string) (*prometheus.GaugeVec, error) + NewHistogram func(name, description string) (prometheus.Histogram, error) + NewHistogramVec func(name, description string, labelNames ...string) (*prometheus.HistogramVec, error) + NewScopedMetricName func(name string) string + NewStopWatch func(name, description string, scale time.Duration) (StopWatch, error) + NewStopWatchVec func(name, description string, scale time.Duration, labelNames ...string) (*StopWatchVec, error) + NewSubScope func(name string) Scope + NewSummary func(name, description string) (prometheus.Summary, error) + NewSummaryVec func(name, description string, labelNames ...string) (*prometheus.SummaryVec, error) + NewSummaryWithOptions func(name, description string, options SummaryOptions) (prometheus.Summary, error) + func NewScope(name string) Scope + func NewTestScope() Scope + type StopWatch struct + func (s StopWatch) Observe(start, end time.Time) + func (s StopWatch) Start() Timer + func (s StopWatch) Time(f func()) + type StopWatchVec struct + func (s StopWatchVec) GetMetricWith(labels prometheus.Labels) (StopWatch, error) + func (s StopWatchVec) WithLabelValues(values ...string) StopWatch + type SummaryOptions struct + Objectives map[float64]float64 + type Timer struct + func (s Timer) Stop() float64