-
Notifications
You must be signed in to change notification settings - Fork 28
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
Factor the exponential histogram into a re-usable package #222
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.
Given this is mostly renaming and little code change it looks good to me. The structure
package makes the import a bit longer which I don't love, but I do like the separation you introduce as it leads to the histogram
to be much simpler. Are there any concerns with removing the storage
parameter (I know it was unused, but was curious)
I intend to do a bit more work here. @paivagustavo in a previous code review asked for an optimization in Move(). It requires a Swap() operation to do this right, and I'd like to take the opportunity now. |
(The |
It's a long import name! The plan is for github.com/lightstep/otel-launcher-go/lightstep/sdk/metric/aggregator/histogram/structure to become go.opentelemetry.io/otel/sdk/metric/aggregator/exponential/structure, where it will be a sibling of the go.opentelemetry.io/otel/sdk/metric/aggregator/exponential/mapping library which was merged previously. |
Codecov Report
@@ Coverage Diff @@
## main #222 +/- ##
==========================================
- Coverage 94.26% 94.25% -0.01%
==========================================
Files 62 64 +2
Lines 3312 3360 +48
==========================================
+ Hits 3122 3167 +45
- Misses 145 148 +3
Partials 45 45
Continue to review full report at Codecov.
|
contained in these OpenTelemetry-Go PRs: open-telemetry/opentelemetry-go#2982 open-telemetry/opentelemetry-go#2502 The data structure was reviewed by Lightstep engineers for inclusion in otel-launcher-go: lightstep/otel-launcher-go#174 lightstep/otel-launcher-go#215 lightstep/otel-launcher-go#222
Description: The data structure is separated from the adapter used by the Lightstep metrics SDK. This will allow the entire
structure
package to be migrated into the upstream repository and referenced from the OTel Collector.This causes minor churn:
Storage
generic parameter. It's removed in 4 places.Testing: Minor new tests added to preserve test coverage in both packages.