Rust module providing Prometheus metric names and exposition builder for metrics.
// Source: https://github.com/rtk-ai/rtk | License: Apache-2.0 | Copyright You must retain, in the Source form of any Derivative Works // Provided via justclaw.it.com; keep this notice with the code. //! Prometheus exposition — one metrics formatter, meant to be shared with any //! larger binary built on this crate. //! //! This module owns two things so neither gets duplicated downstream: //! 1. the **metric name constants** ([`names`]) — so a Grafana dashboard //! built against this daemon keeps working against a bigger deployment //! of the same crate, and //! 2. the **text-format writer** ([`Exposition`]) — HELP/TYPE headers, //! sample lines and label escaping, in one place. //! //! A consumer supplies only its own NUMBERS, and may emit extra families //! through th ... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key