-
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
[prometheusreceiver] should handle histograms without sums #7546
Comments
While trying to implement this, i've realized that there isn't a way to compute the sum from the buckets. The buckets have the count in each bucket, which is insufficient to produce a sum. I'll need to make an adjustment to the spec. |
One other observation is that the current behavior for the prometheus reciever + prometheusremotewrite exporter will add an additional metric for the sum that is always 0, which isn't correct. |
Good news. Once we update the opentelemetry-proto to include open-telemetry/opentelemetry-proto#366 (should be in 0.15.0, once it is released), we will be able to leave the field unset, which will fix the extra _sum metric described above. |
I was able to implement the change for the prometheus receiver and prometheus remote write exporter easily. I've opened prometheus/client_golang#1023 to try and make it possible in the prometheus exporter. |
This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping |
This issue has been closed as inactive because it has been stale for 120 days with no activity. |
This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping |
This issue has been closed as inactive because it has been stale for 120 days with no activity. |
According to the OpenMetrics specification for histograms,
_sum
metrics are not be produced by prometheus clients when there are negative observations.We should handle this case by calculating the sum of all buckets.That isn't possible. We should handle this case by leaving the sum field unset. The current behavior appears to be to produce an OTLP histogram with a sum of 0.This is blocked on opentelemetry-proto being updated to v0.15.0
cc @Aneurysm9 @MrAlias
The text was updated successfully, but these errors were encountered: