diff --git a/CHANGELOG.md b/CHANGELOG.md index 0a70e9df796..1905faf26c1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,7 +11,6 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm ## Changed - Skip links with invalid span context. (#2275) - - Metrics API cleanup. The `metric/sdkapi` package has been created to relocate the API-to-SDK interface: - The following interface types simply moved from `metric` to `metric/sdkapi`: `Descriptor`, `MeterImpl`, `InstrumentImpl`, `SyncImpl`, `BoundSyncImpl`, `AsyncImpl`, `AsyncRunner`, `AsyncSingleRunner`, and `AsyncBatchRunner` - The following struct types moved and are replaced with type aliases, since they are exposed to the user: `Observation`, `Measurement`. diff --git a/metric/metric.go b/metric/metric.go index 74e4f52bff8..d8c5a6b3f35 100644 --- a/metric/metric.go +++ b/metric/metric.go @@ -51,11 +51,17 @@ func WrapMeterImpl(impl sdkapi.MeterImpl) Meter { // Measurement is used for reporting a synchronous batch of metric // values. Instances of this type should be created by synchronous // instruments (e.g., Int64Counter.Measurement()). +// +// Note: This is an alias because it is a first-class member of the +// API but is also part of the lower-level sdkapi interface. type Measurement = sdkapi.Measurement // Observation is used for reporting an asynchronous batch of metric // values. Instances of this type should be created by asynchronous // instruments (e.g., Int64GaugeObserver.Observation()). +// +// Note: This is an alias because it is a first-class member of the +// API but is also part of the lower-level sdkapi interface. type Observation = sdkapi.Observation // RecordBatch atomically records a batch of measurements.