opentelemetry-go-contrib
opentelemetry-go-contrib copied to clipboard
Implement go.schedule.duration
Fixes https://github.com/open-telemetry/opentelemetry-go-contrib/issues/5974.
This uses the same method for estimating the sum as the prometheus client-go: https://github.com/prometheus/client_golang/blob/46f77a97fa1e83e7285634745bd5c92c11bf20c7/prometheus/go_collector_latest.go#L543, which is to use the lower-bound of each bucket as the value of each observation.
It implements this using a metric producer. It is designed to be used together with existing runtime instrumentation.
Codecov Report
Attention: Patch coverage is 86.66667% with 12 lines in your changes missing coverage. Please review.
Project coverage is 65.7%. Comparing base (
6ffea7b) to head (2950bc4).
Additional details and impacted files
@@ Coverage Diff @@
## main #5991 +/- ##
=======================================
+ Coverage 65.5% 65.7% +0.2%
=======================================
Files 203 203
Lines 12985 13034 +49
=======================================
+ Hits 8506 8569 +63
+ Misses 4219 4204 -15
- Partials 260 261 +1
| Files with missing lines | Coverage Δ | |
|---|---|---|
| instrumentation/runtime/runtime.go | 80.9% <95.2%> (+2.4%) |
:arrow_up: |
| instrumentation/runtime/options.go | 88.4% <72.7%> (-11.6%) |
:arrow_down: |
| instrumentation/runtime/producer.go | 86.2% <86.2%> (ø) |