Skip to content

Add exponential histogram support to the cumulative-to-delta processor#44106

Merged
TylerHelmuth merged 9 commits intoopen-telemetry:mainfrom
jade-guiton-dd:cumulative-to-delta-exp-hist
Nov 19, 2025
Merged

Add exponential histogram support to the cumulative-to-delta processor#44106
TylerHelmuth merged 9 commits intoopen-telemetry:mainfrom
jade-guiton-dd:cumulative-to-delta-exp-hist

Conversation

@jade-guiton-dd
Copy link
Contributor

@jade-guiton-dd jade-guiton-dd commented Nov 7, 2025

Description

This PR adds support for exponential histograms to the cumulative-to-delta processor, which currently lacks it.

Along the way, I also:

  • made a small change in pdatatest so that nil and an empty slice are considered equal for exponential histogram buckets, since (as far as I know) they have the same semantics. This is somewhat necessary because a newly-created pcommon.UInt64Slice will be nil, but once filled, there is no way to reset it back to nil: the best you get is an empty slice.
  • modified convertHistogramDataPoints to take a typed argument instead of any, like was done in [chore] avoid unnecessary use of any in CumulativeToDeltaProcessor #35166.

Link to tracking issue

N/A

Testing

I added two simple test cases to the existing test.

Documentation

I updated the README to reflect the added support.

@jade-guiton-dd jade-guiton-dd marked this pull request as ready for review November 10, 2025 13:35
@github-actions github-actions bot added processor/cumulativetodelta Cumulative To Delta processor pkg/pdatatest labels Nov 10, 2025
Copy link
Member

@TylerHelmuth TylerHelmuth left a comment

Choose a reason for hiding this comment

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

I cant verify the math, but the hookup looks good.

# Conflicts:
#	processor/cumulativetodeltaprocessor/README.md
#	processor/cumulativetodeltaprocessor/go.mod
@TylerHelmuth TylerHelmuth merged commit d60cd9f into open-telemetry:main Nov 19, 2025
189 checks passed
@github-actions github-actions bot added this to the next release milestone Nov 19, 2025
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