metricsref

command
v0.5.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 6, 2026 License: Apache-2.0 Imports: 13 Imported by: 0

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

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL