You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Part of #1912. Depends on #1939 (merged).
Blocks content negotiation (PR 1) and OM2 suffix handling in #1947.
Motivation
The OM2 feature flags from #1939 exist but there's no OM2 writer
to apply them to. Content negotiation and suffix handling both need
an OM2 writer class to land their changes in.
When OM2 is enabled: findWriter() prefers OM2 over OM1
When OM2 is not enabled: OM2 writer is not used
No new suffix logic, no composite values, no native histograms
Testability
With OM2 enabled and contentNegotiation=false (default), the OM2
writer is always selected for OpenMetrics requests — masquerades as
OM1 so it's testable with current Prometheus.
Content negotiation then gates it: only route to OM2 when the
scraper sends version=2.0.0.
Open question: Does Prometheus reject responses with Content-Type: ...; version=2.0.0 when it asked for OM1? If so,
use the OM1 content type string when contentNegotiation=false.