Issue in OTel agent with custom trace header propagator (TextMapPropagator) #12372
-
Hi All, I am trying to include custom trace header propagation for OTel agent to use custom headers.
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
Agent can be customized with extensions, see https://github.com/open-telemetry/opentelemetry-java-instrumentation/tree/main/examples/extension. Try passing the jar that contains your propagator to the agent with |
Beta Was this translation helpful? Give feedback.
otel.propagators
does not accept a propagator class name but a comma separated list of propagator names.TextMapPropagator
is not an SPI so having it underMETA-INF/services
will not work. Please see the demo propagator in the sample extension https://github.com/open-telemetry/opentelemetry-java-instrumentation/blob/main/examples/extension/src/main/java/com/example/javaagent/DemoPropagatorProvider.java Besides theTextMapPropagator
you'll have to provide aConfigurablePropagatorProvider
implementation and also theMETA-INF/services
file for that.