Documentation
¶
Overview ¶
Package metrics exposes a Prometheus registry, an HTTP handler to scrape it, and a middleware that records request count and latency. Services register their own collectors on the provided registry.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Metrics ¶
type Metrics struct {
Registry *prometheus.Registry
// contains filtered or unexported fields
}
Metrics bundles a registry with the standard HTTP request collectors.
func New ¶
New builds a Metrics with a fresh registry and registers Go runtime and process collectors plus HTTP request collectors.
Click to show internal directories.
Click to hide internal directories.