You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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 <[email protected]>
* Add test unregistered callback is not called
Co-authored-by: Aaron Clawson <[email protected]>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+6-4
Original file line number
Diff line number
Diff line change
@@ -8,14 +8,16 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
8
8
9
9
## [Unreleased]
10
10
11
-
### Removed
12
-
13
-
- The deprecated `go.opentelemetry.io/otel/sdk/metric/view` package is removed. (#3520)
14
-
15
11
### Added
16
12
13
+
- Return a `Registration` from the `RegisterCallback` method of a `Meter` in the `go.opentelemetry.io/otel/metric` package.
14
+
This `Registration` can be used to unregister callbacks. (#3522)
17
15
- Add `Producer` interface and `Reader.RegisterProducer(Producer)` to `go.opentelemetry.io/otel/sdk/metric` to enable external metric Producers. (#3524)
18
16
17
+
### Removed
18
+
19
+
- The deprecated `go.opentelemetry.io/otel/sdk/metric/view` package is removed. (#3520)
20
+
19
21
### Changed
20
22
21
23
- Global error handler uses an atomic value instead of a mutex. (#3543)
0 commit comments