Loading
feat(metrics): expose the running build as a build_info gauge
Registers gitlab_artifact_registry_build_info{version="<version>"} 1 at boot, the standard build-info gauge, so the deployed version per environment is readable from Prometheus (count by (version) collapses the fleet to the set of builds running). This is the interim we committed to in runway/team#1022 while Runway has no platform-provided deployment-version signal.
Design notes:
- The version reuses LabKit's
app.Version— the same-ldflags -Xvalue already stamped on every log record'sversionfield and handed toserver.BuildInfo. No new version plumbing. versionis a constant label (one series per process, the standardbuild_infoshape). Constant labels are invisible toAuditCardinality, which walks variable labels only, so the label deliberately has nointernal/metrics/cardinality.goentry;TestBuildInfoUnderAuditpins that, and fails pointing at the table if the label is ever converted to a variable one.- The catalog row's Owner is
N/A: no spec declares this metric, and specs are frozen point-in-time.
No e2e scenario is added or affected: the change is observability-only (a constant gauge on /-/metrics), with no request-path or protocol behavior.
Closes #1080 (closed)
Edited by João Pereira