Skip to content

Enable native histograms by default - #7968

Open
SungJin1212 wants to merge 5 commits into
cortexproject:masterfrom
SungJin1212:enable-native-histograms-by-default
Open

SungJin1212 wants to merge 5 commits into
cortexproject:masterfrom
SungJin1212:enable-native-histograms-by-default

Conversation

@SungJin1212

Copy link
Copy Markdown
Member

What this PR does:
Changes the default of -blocks-storage.tsdb.enable-native-histograms (enable_native_histograms) from false to true, so native histograms are ingested without extra configuration in Cortex.

Native histograms are stable in Prometheus since v3.8, and the Cortex flag graduated from experimental in #7789. With the old default, the ingester discards native histogram samples while the push still succeeds.

The flag can still be set to false, globally or per tenant.

Which issue(s) this PR fixes:
Fixes #

Checklist

  • Tests updated
  • Documentation added
  • CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]
  • docs/configuration/v1-guarantees.md updated if this PR introduces experimental flags

@SungJin1212
SungJin1212 requested a review from a team as a code owner November 25, 2026 07:26
@SungJin1212
SungJin1212 requested a review from yeya24 November 25, 2026 07:26

@sandy2008 sandy2008 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only the ingester push path reads this limit, and an explicit false still wins globally and per tenant. Tests pass and the generated reference matches. LGTM.

Comment thread docs/guides/native-histograms.md Outdated
enable_native_histograms: <bool>
```
<!-- TODO: Update this guide when v1.23.0 is released: native histogram ingestion is enabled by default, document how to disable it and the recommended limits. -->
By default, it is disabled, so make sure to enable it if you need native histograms for your system monitoring.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: this still says disabled by default. Maybe:

Suggested change
By default, it is disabled, so make sure to enable it if you need native histograms for your system monitoring.
It is enabled by default since v1.23.0 and disabled by default in earlier versions. Set it to `false` to discard native histogram samples.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, I applied it to the latest commit.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants