Skip to content

[DEMO] PromQL NHCB-as-classic conversion - #5

Draft
bwplotka wants to merge 4 commits into
bwplotka/pr-18048-label-controlfrom
demo-pr-19883
Draft

bwplotka wants to merge 4 commits into
bwplotka/pr-18048-label-controlfrom
demo-pr-19883

Conversation

@bwplotka

@bwplotka bwplotka commented Oct 1, 2026

Copy link
Copy Markdown
Owner

…icQuerier

Group stored classic and converted NHCB series by histogram identity (labels excluding __name__ and le) when both representations exist, while keeping pure NHCB SeriesSets streaming lazily one NHCB series at a time:
- Stored classic samples take precedence at matching timestamps, shadowing converted NHCB buckets across the group even when bucket layouts or le formatting differ.
- Disjoint time ranges across a migration cutover merge into a single continuous series, with staleness markers handled per representation.
- NHCB staleness markers, dropped custom buckets, and classic takeover timestamps emit StaleNaN on active converted series.
- Series are sorted by labels.Compare (per group when sortSeries=false, globally when sortSeries=true).

Signed-off-by: Bartek Plotka <bwplotka@google.com>
…ebug label

Add per-selector control over NHCB-to-classic conversion via the reserved
__nhcb_as_classic__ matcher and optional __from_nhcb__ provenance output label:
- __nhcb_as_classic__="true" (or !="false") enables conversion for the selector.
- __nhcb_as_classic__="false" (or !="true", ="") disables conversion and returns
  stored classic series only.
- __nhcb_as_classic__="debug" (or =~"true|debug") enables conversion and attaches
  __from_nhcb__="true" to series converted from NHCB and __from_nhcb__="false"
  to stored classic series.

Signed-off-by: Bartek Plotka <bwplotka@google.com>
…rsion

Runs Prometheus with --enable-feature=promql-nhcb-as-classic on localhost:1234, scraping itself with 5 jobs (classic, nhcb, classic-and-nhcb, native, classic-and-native) and opening browser tabs comparing classic and native histogram queries with __nhcb_as_classic__ and __from_nhcb__.

Signed-off-by: Bartek Plotka <bwplotka@google.com>
…t demo

deploy.sh builds Prometheus from GIT_REF with the prebuilt web UI and runs it with --enable-feature=promql-nhcb-as-classic and demo_histcompat.yaml on a single small GCE VM (prom-nhcb-compat-demo), behind Caddy with automatic Let's Encrypt TLS for <ip>.sslip.io (or DOMAIN).

Signed-off-by: Bartek Plotka <bwplotka@google.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant