Skip to content

docs: fix the documentation on the limit ranges for fixed bucket histograms - #19974

Open
hngu wants to merge 1 commit into
apache:masterfrom
hngu:doc-update-fixed-histogram-doc
Open

docs: fix the documentation on the limit ranges for fixed bucket histograms#19974
hngu wants to merge 1 commit into
apache:masterfrom
hngu:doc-update-fixed-histogram-doc

Conversation

@hngu

@hngu hngu commented Aug 11, 2026

Copy link
Copy Markdown

Fixes #19891.

Description

In this doc (https://druid.apache.org/docs/latest/development/extensions-core/approximate-histograms/#properties) for fixed bucket histograms, it shows that the range [lowerLimit, upperLimit] will be divided into numBuckets intervals of equal size with closed bracket notation. This means inclusivity. However, in the code itself it actually indicates [lowerLimit, upperLimit) which does not include the upperLimit: https://github.com/apache/druid/blob/master/extensions-core/histogram/src/main/java/org/apache/druid/query/aggregation/histogram/FixedBucketsHistogram.java#L389-L396

I am updating the docs to reflect what the code actually does.

Release note

Skipped

This PR has:

  • been self-reviewed.
  • added documentation for new or modified features or behaviors.
  • a release note entry in the PR description.
  • added Javadocs for most classes and all non-trivial methods. Linked related entities via Javadoc links.
  • added or updated version, license, or notice information in licenses.yaml
  • added comments explaining the "why" and the intent of the code wherever would not be obvious for an unfamiliar reader.
  • added unit tests or modified existing tests to cover new code paths, ensuring the threshold for code coverage is met.
  • added integration tests.
  • been tested in a test Druid cluster.

@FrankChen021 FrankChen021 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I have reviewed the code for correctness, edge cases, concurrency, and integration risks; no issues found.

Reviewed 2 of 2 changed files.


This is an automated review by Codex GPT-5.6-Luna(max)

@hngu hngu changed the title doc: fix the documentation on the limit ranges for fixed bucket histograms docs: fix the documentation on the limit ranges for fixed bucket histograms Aug 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fix documentation for FixedBucketHistogram

2 participants