Skip to main content

Module metrics

Module metrics 

Source
Expand description

Prometheus metrics for monitoring calls and server load.

GET metrics::PATH returns 200 OK in Prometheus text exposition format with content type metrics::CONTENT_TYPE. Configure Prometheus to scrape this endpoint. Send PromQL queries to Prometheus, for example:

sum(osfu_users_active)
sum by (stage) (rate(osfu_ws_connections_total[5m]))

metrics::MetricName lists exported names and their meanings. The scrape response includes each metric’s HELP, TYPE and labels.

Enums§

MetricName
Names every exported Prometheus metric family.

Constants§

CONTENT_TYPE
PATH
Prometheus scrape endpoint, not a PromQL API. See crate::http::telemetry::metrics for queries and examples.