Class TestPropagator
java.lang.Object
org.eclipse.microprofile.telemetry.tracing.tck.rest.TestPropagator
- All Implemented Interfaces:
io.opentelemetry.context.propagation.TextMapPropagator
public class TestPropagator
extends Object
implements io.opentelemetry.context.propagation.TextMapPropagator
A basic propagator for span context and baggage
Span information is passed in the TEST-SPAN key with format
traceId;spanId;flags;statekey1=value,statekey2=value
Baggage information is passed in the TEST-BAGGAGE key with format
key,value,metadata;key2,value,metadata;key3,value,metadata;...
All individual values are urlencoded to make parsing easy (don't have to worry about values containing separator characters)
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<C> io.opentelemetry.context.Contextextract(io.opentelemetry.context.Context context, C carrier, io.opentelemetry.context.propagation.TextMapGetter<C> getter) fields()<C> voidinject(io.opentelemetry.context.Context context, C carrier, io.opentelemetry.context.propagation.TextMapSetter<C> setter)
-
Field Details
-
BAGGAGE_KEY
- See Also:
-
TRACE_KEY
- See Also:
-
-
Constructor Details
-
TestPropagator
public TestPropagator()
-
-
Method Details
-
fields
- Specified by:
fieldsin interfaceio.opentelemetry.context.propagation.TextMapPropagator
-
extract
public <C> io.opentelemetry.context.Context extract(io.opentelemetry.context.Context context, C carrier, io.opentelemetry.context.propagation.TextMapGetter<C> getter) - Specified by:
extractin interfaceio.opentelemetry.context.propagation.TextMapPropagator
-
inject
public <C> void inject(io.opentelemetry.context.Context context, C carrier, io.opentelemetry.context.propagation.TextMapSetter<C> setter) - Specified by:
injectin interfaceio.opentelemetry.context.propagation.TextMapPropagator
-