Skip to content

Conversation

carrieedwards
Copy link
Contributor

@carrieedwards carrieedwards commented Jan 21, 2025

This PR adds the functionality to convert OTel explicit histograms into Custom Buckets Native Histograms via a configuration option.

Issue: #15022
Part of: #13485

@carrieedwards carrieedwards force-pushed the cedwards/otel-hist-to-nhcb branch from 8cb4d0c to 5489b67 Compare January 21, 2025 16:28
@bwplotka
Copy link
Member

Nice, good idea!

@krajorama krajorama self-requested a review March 5, 2025 15:00
Copy link
Member

@krajorama krajorama left a comment

Choose a reason for hiding this comment

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

Looking good. For this to work end-to-end we'll have to update

func (h Histogram) ToFloatHistogram() *histogram.FloatHistogram {

and
func (h Histogram) ToIntHistogram() *histogram.Histogram {

@krajorama
Copy link
Member

Also we'll probably need a setting to limit maximum bucket count - and error out if it we go over.

@carrieedwards carrieedwards force-pushed the cedwards/otel-hist-to-nhcb branch 2 times, most recently from 46a35c2 to e3edb69 Compare March 17, 2025 21:34
@carrieedwards carrieedwards marked this pull request as ready for review March 18, 2025 15:51
Copy link
Contributor

@aknuds1 aknuds1 left a comment

Choose a reason for hiding this comment

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

Generally LGTM, but see comments :)

Copy link
Contributor

@aknuds1 aknuds1 left a comment

Choose a reason for hiding this comment

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

Could you add the new convert_histograms_to_nhcb configuration parameter to docs/configuration/configuration.md? Also, should there be a FEATURE changelog entry?

@aknuds1
Copy link
Contributor

aknuds1 commented Mar 18, 2025

A conflict needs resolving.

@carrieedwards carrieedwards force-pushed the cedwards/otel-hist-to-nhcb branch from ca7fbed to 835eb94 Compare March 18, 2025 22:27
@aknuds1 aknuds1 self-requested a review March 19, 2025 05:02
Copy link
Contributor

@aknuds1 aknuds1 left a comment

Choose a reason for hiding this comment

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

Thanks for doing this! LGTM, except you should fix the changelog ordering.

Copy link
Member

@krajorama krajorama left a comment

Choose a reason for hiding this comment

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

LGTM

Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
…hema

Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
@carrieedwards carrieedwards force-pushed the cedwards/otel-hist-to-nhcb branch from f9efbe1 to 84bdc4f Compare March 20, 2025 15:45
@carrieedwards carrieedwards changed the title Optionally translate OTEL histograms to NHCB Optionally translate OTel histograms to NHCB Mar 20, 2025
@carrieedwards carrieedwards merged commit c90b387 into main Mar 20, 2025
46 checks passed
@carrieedwards carrieedwards deleted the cedwards/otel-hist-to-nhcb branch March 20, 2025 16:18
slashpai added a commit to slashpai/prometheus-operator that referenced this pull request May 17, 2025
Related-to prometheus/prometheus#15850

Signed-off-by: Jayapriya Pai <slashpai9@gmail.com>
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.

4 participants