proposal: Prometheus internal telemetry as an OTel semantic convention registry - #86
Open
nicolastakashi wants to merge 1 commit into
Open
Conversation
nicolastakashi
force-pushed
the
semconv-internal-telemetry
branch
2 times, most recently
from
June 29, 2026 09:46
459e052 to
293d5de
Compare
Member
|
I would like to assess what alternatives we have that could be built-in e.g. client_golang and would be lighter. And I would also want to better understand the scope of this: |
nicolastakashi
force-pushed
the
semconv-internal-telemetry
branch
from
August 18, 2026 20:19
2dac915 to
63633cc
Compare
…n registry Define every metric the Prometheus binary exposes in a single OTel semantic convention registry, and use it as the source of truth for instrumentation code, documentation, and contract testing. Instrumentation code and per-package documentation are generated from the registry with Weaver, so neither can drift from the schema. Weaver is confined to build-time authoring. Contract testing runs without a Collector or a Weaver binary. `promtool check metrics --schema` validates a running Prometheus from outside and works for any exporter in any language. An in-process check over `Collector.Describe()` also covers metrics that never produce a sample, which telemetry-based validation cannot see. Both need a small, dependency-free addition to client_golang, since `prometheus.Desc` exposes no structural accessors today. Stability levels are recorded as schema information so lifecycle can be expressed and changes to it reviewed. Defining what `stable` obligates, how long a deprecation cycle runs, and which existing metrics are stable is left to a follow-on proposal. A consumable registry also lets downstream projects detect drift themselves. awesome-prometheus-alerts hardcodes 37 distinct prometheus_* metric names and perses/community-mixins writes them into dashboard queries, with no way to validate either against a release. Publishing a versioned schema of renames between releases stays a follow-on.
nicolastakashi
force-pushed
the
semconv-internal-telemetry
branch
from
August 18, 2026 20:27
63633cc to
52b69ae
Compare
Author
@roidelapluie thanks for comment, I've updated a few things in the doc aiming to cover what you raised, let me know your thoughts |
nicolastakashi
marked this pull request as ready for review
August 24, 2026 16:16
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This proposal defines all metrics exported by the Prometheus binary as a formal OTel semantic convention registry. Making the schema machine-readable enables auto-generated instrumentation code, always-in-sync documentation, contract testing against live instances, and a lifecycle model for safe metric evolution across the Prometheus ecosystem.
Proof-of-concept implementation: prometheus/prometheus#17868