MCPcopy Create free account
hub / github.com/imgproxy/imgproxy / Prometheus

Struct Prometheus

monitoring/prometheus/prometheus.go:25–37  ·  view source on GitHub ↗

Prometheus holds Prometheus metrics and configuration

Source from the content-addressed store, hash-verified

23
24// Prometheus holds Prometheus metrics and configuration
25type Prometheus struct {
26 config *Config
27 stats *stats.Stats
28
29 requestsTotal prometheus.Counter
30 statusCodesTotal *prometheus.CounterVec
31 errorsTotal *prometheus.CounterVec
32
33 requestDuration prometheus.Histogram
34 requestSpanDuration *prometheus.HistogramVec
35
36 workers prometheus.Gauge
37}
38
39// New creates a new Prometheus instance
40func New(config *Config, stats *stats.Stats) (*Prometheus, error) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected