OpenTelemetry - java
Notes
no notes yet
API
🛠️ Bugfixes
- Usages of tracers and meters on all
OpenTelemetryinstances were being delegated to the global Meter and Tracer. This has been corrected, and all instances should have independent Tracer and Meter instances.
☢️ Breaking Changes
- The
AttributesBuilderno long accepts null values for array-valued attributes with numeric or boolean types. - The
TextMapPropagator.fields()method now returns aCollectionrather than aList. Labelshas been converted to an interface, from an abstract class. Its API has otherwise remained the same.TraceStatehas been converted to an interface, from an abstract class. Its API has otherwise remained the same.Attributeshas been converted to an interface, from an abstract class. Its API has otherwise remained the same.- The
ReadableAttributesinterface has been removed, as it was redundant with theAttributesinterface. All APIs that used or returnedReadableAttributesshould accept or return standardAttributesimplementations. SpanContexthas been converted to an interface, from an abstract class. Its API has otherwise remained the same.- The functional
AttributeConsumerinterface has been removed and replaced with a standardjava.util.function.BiConsumer. - The signature of the
BaggageBuilder.put(String, String, EntryMetadata entryMetadata)method has been changed toput(String, String, BaggageEntryMetadata)
📈 Enhancements
- A
builder()method has been added to the OpenTelemetry interface to facilitate constructing implementations. - An
asMap()method has been added to theAttributesinterface to enable conversion to a standardjava.util.Map. - An
asMap()method has been added to theBaggageinterface to enable conversion to a standardjava.util.Map. - An
asMap()method has been added to theTraceStateinterface to enable conversion to a standardjava.util.Map. - The Semantic Attributes constants have been updated to the version in the yaml spec as of Dec 1, 2020.
🌟 Miscellaneous
- The
HttpTraceContextclass has been deprecated in favor ofW3CTraceContextPropagator.HttpTraceContextwill be removed in 0.13.0. - The
toBuilder()method on the OpenTelemetry interface has been deprecated and will be removed in 0.13.0. - The
DefaultContextPropagatorsclass has been deprecated. Access to it will be removed in 0.13.0. - The
TraceMultiPropagatorbuilder has been deprecated in favor of a simple factory method. The builder will be removed in 0.13.0. You can access the same functionality via static methods on theContextPropagatorsinterface. - The
setCallback()method on the asynchronous metric instruments has been deprecated and will be removed in 0.13.0. Instead, use thesetCallback()method on the builder for the instruments. - The
value()method on theStatusCodeenum has been deprecated and will be removed in 0.13.0. - The Baggage
EntryMetadataclass has been deprecated in favor of theBaggageEntryMetadatainterface. The class will be made non-public in 0.13.0.
Extensions
- The
opentelemetry-extension-runtime-metricsmodule has been deprecated. The functionality is available in the opentelemetry-java-instrumentation project under a different module name. The module here will be removed in 0.13.0. - The
trace-utilsmodule has been deprecated. If you need this module, please let us know! The module will be removed in 0.13.0.
SDK
☢️ Breaking Changes
- The
opentelemetry-sdk-tracingmodule has been renamed toopentelemetry-sdk-trace. - The default port the OTLP exporters use has been changed to
4317. - The deprecated
SpanData.getCanonicalCode()method has been removed, along with the implementations.
📈 Enhancements
- The OpenTelemetrySdk builder now supports the addition of
SpanProcessors to the resulting SDK. - The OpenTelemetrySdk builder now supports the assignment of an
IdGeneratorto the resulting SDK. - The
ReadableSpaninterface now exposes theSpan.Kindof the span. - The SDK no longer depends on the guava library.
- The parent SpanContext is now exposed on the
SpanDatainterface.
🌟 Miscellaneous
- The
toBuilder()method on the OpenTelemetrySdk class has been deprecated and will be removed in 0.13.0. - The MultiSpanProcessor and MultiSpanExporter have been deprecated. You can access the same functionality via
the
SpanProcessor.compositeandSpanExporter.compositemethods. The classes will be made non-public in 0.13.0. - The
SpanData.hasRemoteParent()method has been deprecated and will be removed in 0.13.0. If you need this information, you can now callSpanData.getParentSpanContext().isRemote(). - The default timeouts for the 2 OTLP exporters and the Jaeger exporter have been changed to 10s from 1s.
Extensions
☢️ Breaking Changes
- The
opentelemetry-sdk-extension-aws-v1-supportmodule has been renamed toopentelemetry-sdk-extension-awsand the classes in it have been repackaged into theio.opentelemetry.sdk.extension.aws.*packages.
🛠️ Bugfixes:
- The OpenTracing
TracerShimnow properly handles keys for context extraction in a case-insensitive manner.
📈 Enhancements
- The
opentelemetry-sdk-extension-resourcesnow includes resource attributes for the process runtime via theProcessRuntimeResourceclass. This is included in the Resource SPI implementation that the module provides. - The
opentelemetry-sdk-extension-awsextension now will auto-detect AWS Lambda resource attributes.