Documentation
¶
Overview ¶
Command metricsref regenerates the table of the metrics reference page (website/content/reference/metrics.md) from the collectors the server registers, so the page lists every metric family it exports.
The page stays hand-written prose around one generated block, the text between
<!-- BEGIN GENERATED metricsref --> <!-- END GENERATED metricsref -->
whose body is replaced on every run. Names, help text and labels come from each collector's descriptors; the type from the collector itself, or, for a custom collector, from the name (a _total suffix is a counter).
Usage, from the repository root:
go run ./internal/tools/metricsref # rewrite the page go run ./internal/tools/metricsref -check # fail when the page is stale
Click to show internal directories.
Click to hide internal directories.