-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
[pkg/translator/prometheusremotewrite] Improve performance of conversion to Prometheus remote write format #24288
[pkg/translator/prometheusremotewrite] Improve performance of conversion to Prometheus remote write format #24288
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good job! The changes make sense to me 👍
Because the benchmarks in the PR description are not super readable:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Note that we're already running these in production in our hosted-Prometheus product which can accept OTLP data and seeing similar performance improvements.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Given that @Aneurysm9 is the sole code owner but is currently on PTO, I'm approving this as I trust the other reviewers.
Description:
This PR improves the performance of the conversion from OpenTelemetry to Prometheus remote write. It reduces latency and memory utilisation by up to 70% in some cases, particularly those involving histograms, summaries or series with many labels.
Benchmark results
Link to tracking Issue: (none)
Testing: I've added a benchmark to verify the improvement, and run the existing tests to ensure these changes have not introduced any regressions.
Documentation: (none required)