Skip to main content

describe_metrics

Function describe_metrics 

Source
pub fn describe_metrics() -> Vec<(String, String, &'static str)>
Expand description

Returns the (name, help, source) of every metric this crate registers through a metric!-wrapping macro (lgalloc and rusage).

The metrics catalog (mz-metrics-catalog) builds the user-facing metrics docs by scraping metric! invocations out of the source with syn. These metrics are invisible to that scraper because their names are assembled at macro-expansion time, so the catalog imports them from here instead: it registers them into a throwaway registry and reads their descriptors back out.