Version 0.10.0 contains very many breaking changes, especially in the APIs. This will probably be an extremely disruptive release for direct users of our APIs. If you need help migrating from older versions to 0.10.0, please reach out on gitter, and we’ll be happy to help. This release can be considered Milestone 1 for the Tracing, Context and Baggage APIs.
Changes since 0.9.1:
API
Enhancements
- The W3C Baggage Propagator is now available.
- The B3 Propagator now handles both single and multi-header formats, and defaults to injecting the single-header format.
- Mutating a method on
Span
now returns theSpan
to enable call-chaining.
Bug fixes
- The
package-info
file was removed from theio.otel.context
package because it made the project incompatible with JPMS.
Breaking changes
- There have been many updates to the semantic conventions constants. The constants are now auto-generated from the YAML specification files, so the names will now be consistent across languages. For more information, see the YAML Model for Semantic Conventions.
- All API classes have been moved into the
io.opentelemetry.api.
prefix to support JPMS users. - The API no longer uses the
grpc-context
as the context implementation. It now usesio.opentelemetry.context.Context
. This is published in theopentelemetry-context
artifact. Interactions with the context were mostly moved to static methods in theSpan
andBaggage
interfaces. - The Baggage API has been reworked to more closely match the specification. This includes the removal of the
BaggageManager
. Baggage is fully functional within the API, without needing to install an SDK. TracingContextUtils
andBaggageUtils
were removed from the public API. Instead, use the appropriate static methods on theSpan
andBaggage
classes, or use methods on theContext
itself.- The context propagation APIs have moved into the new
opentelemetry-context
context module. DefaultSpan
was removed from the public API. Instead, useSpan.wrap(spanContext)
if you need a non-functional span that propagates the trace context.DefaultMeter
,DefaultMeterProvider
,DefaultTracer
andDefaultTracerProvider
were removed from the public API. You can access the same functionality withgetDefault()
methods on theMeter
,MeterProvider,
Tracer, and
TracerProvider` classes, respectively.- Some functionality from the
Tracer
interface is now available either on theSpan
interface orContext
interface. - The
OpenTelemetry
class is now an interface, with implementations. Methods on this interface have changed their names to reflect this change. For more information, see OpenTelemetry.java. - All builder-creation methods have been renamed to
.builder()
. StatusCanonicalCode
has been renamed toStatusCode
.Span.getContext()
has been renamed toSpan.getSpanContext()
.AttributesBuilder
now usesput
instead ofadd
as the method name for adding attributes.- All parameters are now marked as non-nullable by default.
TextMapPropagators
could receive a null carrier passed to the extract method.- The
TextMapPropagator.Getter
interface has added a method to return the keys that the propagator uses.
SDK
Enhancements
- A new
MetricData
gauge metric type is now available. - A new
opentelemetry-sdk-testing
module with a JUnit 5 extension to assist with testing is now available. - The Prometheus metric exporter now consumes
gauge
metrics. - The Jaeger gRPC exporter now maps
Resource
entries to process tags. - The OTLP protobuf definitions were updated to the latest released version: 0.6.0. Both the
Span
andMetric
exporters were updated to match. - The
Sampler
interface now allows aSampler
implementation to update theTraceState
that is applied to theSpanContext
for the resulting span.
Breaking changes
TraceConfig
configuration option names (environment variables and system properties) were renamed to match the OpenTelemetery Specification. For more information, see TraceConfig.- The Jaeger gRPC exporter was updated to match the OpenTelemetry Specification. The
message
log entry attribute has been renamed toevent
and a newdropped attributes count
attribute was added. For more information, see the Overview. - The
SpanData.getHasRemoteParent()
andSpanData.getHasEnded()
methods were renamed tohasRemoteParent()
andhasEnded()
, respectively. - The
IdsGenerator
interface has been renamed toIdGenerator
, and all implementations and relevant factory methods were similarly renamed. - The
RandomIdGenerator
is now accessible via a factory method on theIdGenerator
class, rather than being exposed itself. UseIdGenerator.random()
to acquire an instance. - The OTLP metric exporter now emits
gauge
metrics where appropriate. ValueObserver
instruments now generate gauge metrics, rather than non-monotonic counter-style metrics.ValueObserver
instruments now use theLastValue
aggregation instead ofMinMaxSumCount
.- The
SpanData.*
implementation classes were removed from the public SDK, but the interfaces are still available. SpanProcessor.onStart
now takes aContext
as its first parameter.- The
Sampler
interface now takes a parentContext
rather than aSpanContext
. - Each
Sampler
has been reorganized into their own classes and moved into theio.opentelemetry.sdk.trace.samplers
package. Factory methods that used to be on theSamplers
class were moved to theSampler
interface.
Extensions
Enhancements
- A new JUnit5 extension was added for writing tests. For more information, see OpenTelemetryExtension.java.
- A Jaeger
SpanExporter
which exports via thethrift-over-http protocol
is now available. - A Jaeger Propagator is now available.
Breaking changes
- The in-memory exporter(s) have been moved to the
opentelemetry-sdk-testing
artifact. - The OpenTracing shim factory class has been renamed from
TraceShim
toOpenTracingShim
. The factory methods have changed becauseBaggageManager
was removed and non-globalOpenTelemetry
instances are now available. - The 's' was removed from the word "exporters" for every exporter artifact. For example,
opentelemetry-exporters-logging
was renamed toopentelemetry-exporter-logging
. - The 's' was removed from the word "extensions" for the package for every SDK extension. For example,
io.opentelemetry.sdk.extensions.otproto.TraceProtoUtils
was renamed toio.opentelemetry.sdk.extension.otproto.TraceProtoUtils
.
Many thanks to everyone who made this release possible!
@anuraaga @bogdandrutu @Oberon00 @thisthat @HaloFour @jkwatson @kenfinnigan @MariusVolkhart @malafeev @trask @tylerbenson @XiXiaPdx @dengliming @hengyunabc @jarebudev @brianashby-sfx