1
0
mirror of https://github.com/open-telemetry/opentelemetry-go.git synced 2024-12-12 10:04:29 +02:00
opentelemetry-go/sdk
Tyler Yahn 4014204d42
Allow multi-instrument callbacks to be unregistered (#3522)
* Update Meter RegisterCallback method

Return a Registration from the method that can be used by the caller to
unregister their callback.

Update documentation of the method to better explain expectations of
use and implementation.

* Update noop impl

* Update global impl

* Test global Unregister concurrent safe

* Use a map to track reg in global impl

* Update sdk impl

* Use a list for global impl

* Fix prom example

* Lint metric/meter.go

* Fix metric example

* Placeholder for changelog

* Update PR number in changelog

* Update sdk/metric/pipeline.go

Co-authored-by: Aaron Clawson <3766680+MadVikingGod@users.noreply.github.com>

* Add test unregistered callback is not called

Co-authored-by: Aaron Clawson <3766680+MadVikingGod@users.noreply.github.com>
2022-12-16 12:02:42 -08:00
..
instrumentation Revert Adding attributes to the instrumentation scope. 2022-09-09 09:06:58 -05:00
internal Use already enabled revive linter and add depguard (#2883) 2022-05-19 15:15:07 -05:00
metric Allow multi-instrument callbacks to be unregistered (#3522) 2022-12-16 12:02:42 -08:00
resource Decode values from OTEL_RESOURCE_ATTRIBUTES (#2963) 2022-10-19 09:13:20 -07:00
trace attribute: fix slice related function bug (#3252) 2022-10-13 09:34:02 -05:00
go.mod Release v1.11.2/v0.34.0 (#3512) 2022-12-05 13:43:20 -06:00
go.sum dependabot updates Mon Oct 31 15:24:02 UTC 2022 (#3433) 2022-10-31 08:54:41 -07:00