Skip to content

[Messaging] Context propagation not fully working for messaging (with new conventions) #14024

Open
@cbos

Description

@cbos

Is your feature request related to a problem? Please describe.

As described in https://github.com/open-telemetry/semantic-conventions/blob/main/docs/messaging/messaging-spans.md#context-propagation context propagation is supported for spans with messaging.

For example JMS supports sending properties as part of the message, with that traceparent, tracestate and baggage headers are send with the message.
The receiving service can take these properties and reconstruct the context.

With the current/old semantic conventions that is working fine.

Image

But when this feature is enabled it is not working:
otel.instrumentation.messaging.experimental.receive-telemetry.enabled

With this feature spans are linked in the same way as with the new semantic conventions.
See #13192

Image

The headers are still sent, but only span is linked, but the baggage is not propagated.

Describe the solution you'd like

A possible solution is to copy the baggage header on creation of the new context:

Image

Code for this solution can look like this:
ing-bank@91ae29b

Describe alternatives you've considered

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestneeds triageNew issue that requires triage

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions