Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Normalization of exponential histograms correctly handles scale changes #366

Open
dashpole opened this issue Apr 25, 2022 · 3 comments
Open
Labels
Blocked This issue or pull request is waiting on something else, and isn't actionable right now enhancement New feature or request priority: p2

Comments

@dashpole
Copy link
Contributor

Follow-up from #360 (comment).

For normalization of exponential histograms:

  1. If the "start" histogram scale is "lower resolution", then rescale the newest point to the start histogram scale and normalize.
  2. If the "start" histogram scale is "higher resolution" then rescale the start point to the new resolution and REPLACE the cache with this rescaled version, using this version from now forward.
  3. Always ensure scale value is the "lowest resolution" of start, current.

If OTEL hasn't provided a "rescale" method for ExponentialHistogram, it should.

Side note: The "offset" for buckets shouldn't be as important, but MAY matter if we need to lower resolution even further. The crux of the algorithm should remain the same.

@aabmass
Copy link
Contributor

aabmass commented Nov 30, 2022

If OTEL hasn't provided a "rescale" method for ExponentialHistogram, it should.

@dashpole any idea if there is an upstream rescale method yet? Thinking to mark this issue "blocked" until that is available or we could add it upstream. @damemi expressed some interest in working on this.

@dashpole
Copy link
Contributor Author

marking it blocked SGTM.

@damemi damemi added the Blocked This issue or pull request is waiting on something else, and isn't actionable right now label Nov 30, 2022
@aabmass
Copy link
Contributor

aabmass commented Apr 10, 2023

Discussed with team. It would be nice if this was fixed by a processor upstream. We could either log a message or have a self-observability metric to understand if this is happening in practice or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Blocked This issue or pull request is waiting on something else, and isn't actionable right now enhancement New feature or request priority: p2
Projects
None yet
Development

No branches or pull requests

4 participants