v1.15.0
版本发布时间: 2023-04-28 22:53:56
open-telemetry/opentelemetry-go最新发布版本:v1.30.0(2024-09-11 05:35:18)
Added
- The
go.opentelemetry.io/otel/metric/embedded
package. (#3916) - The
Version
function togo.opentelemetry.io/otel/sdk
to return the SDK version. (#3949) - Add a
WithNamespace
option togo.opentelemetry.io/otel/exporters/prometheus
to allow users to prefix metrics with a namespace. (#3970) - The following configuration types were added to
go.opentelemetry.io/otel/metric/instrument
to be used in the configuration of measurement methods. (#3971)- The
AddConfig
used to hold configuration for addition measurements-
NewAddConfig
used to create a newAddConfig
-
AddOption
used to configure anAddConfig
-
- The
RecordConfig
used to hold configuration for recorded measurements-
NewRecordConfig
used to create a newRecordConfig
-
RecordOption
used to configure aRecordConfig
-
- The
ObserveConfig
used to hold configuration for observed measurements-
NewObserveConfig
used to create a newObserveConfig
-
ObserveOption
used to configure anObserveConfig
-
- The
-
WithAttributeSet
andWithAttributes
are added togo.opentelemetry.io/otel/metric/instrument
. They return an option used during a measurement that defines the attribute Set associated with the measurement. (#3971) - The
Version
function togo.opentelemetry.io/otel/exporters/otlp/otlpmetric
to return the OTLP metrics client version. (#3956) - The
Version
function togo.opentelemetry.io/otel/exporters/otlp/otlptrace
to return the OTLP trace client version. (#3956)
Changed
- The
Extrema
ingo.opentelemetry.io/otel/sdk/metric/metricdata
is redefined with a generic argument of[N int64 | float64]
. (#3870) - Update all exported interfaces from
go.opentelemetry.io/otel/metric
to embed their corresponding interface fromgo.opentelemetry.io/otel/metric/embedded
. This adds an implementation requirement to set the interface default behavior for unimplemented methods. (#3916) - Move No-Op implementation from
go.opentelemetry.io/otel/metric
into its own packagego.opentelemetry.io/otel/metric/noop
. (#3941)-
metric.NewNoopMeterProvider
is replaced withnoop.NewMeterProvider
-
- Add all the methods from
"go.opentelemetry.io/otel/trace".SpanContext
tobridgeSpanContext
by embeddingotel.SpanContext
inbridgeSpanContext
. (#3966) - Wrap
UploadMetrics
error ingo.opentelemetry.io/otel/exporters/otlp/otlpmetric/
to improve error message when encountering generic grpc errors. (#3974) - The measurement methods for all instruments in
go.opentelemetry.io/otel/metric/instrument
accept an option instead of the variadic"go.opentelemetry.io/otel/attribute".KeyValue
. (#3971)- The
Int64Counter.Add
method now accepts...AddOption
- The
Float64Counter.Add
method now accepts...AddOption
- The
Int64UpDownCounter.Add
method now accepts...AddOption
- The
Float64UpDownCounter.Add
method now accepts...AddOption
- The
Int64Histogram.Record
method now accepts...RecordOption
- The
Float64Histogram.Record
method now accepts...RecordOption
- The
Int64Observer.Observe
method now accepts...ObserveOption
- The
Float64Observer.Observe
method now accepts...ObserveOption
- The
- The
Observer
methods ingo.opentelemetry.io/otel/metric
accept an option instead of the variadic"go.opentelemetry.io/otel/attribute".KeyValue
. (#3971)- The
Observer.ObserveInt64
method now accepts...ObserveOption
- The
Observer.ObserveFloat64
method now accepts...ObserveOption
- The
- Move global metric back to
go.opentelemetry.io/otel/metric/global
fromgo.opentelemetry.io/otel
. (#3986)
Fixed
-
TracerProvider
allows callingTracer()
while it's shutting down. It used to deadlock. (#3924) - Use the SDK version for the Telemetry SDK resource detector in
go.opentelemetry.io/otel/sdk/resource
. (#3949) - Fix a data race in
SpanProcessor
returned byNewSimpleSpanProcessor
ingo.opentelemetry.io/otel/sdk/trace
. (#3951) - Automatically figure out the default aggregation with
aggregation.Default
. (#3967)
Deprecated
- The
go.opentelemetry.io/otel/metric/instrument
package is deprecated. Use the equivalent types added togo.opentelemetry.io/otel/metric
instead. (#4018)