Skip to content

Propagation: Support extraction of multiple values for a single key #1032

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
jamesmoessis opened this issue May 1, 2025 · 1 comment
Open
Labels
enhancement New feature or request

Comments

@jamesmoessis
Copy link
Contributor

jamesmoessis commented May 1, 2025

In order to fully support W3C baggage specifications (and some others like tracestate), micrometer must be able to receive and extract multiple headers of the same key. For example, two baggage headers.

This is now fully supported by OpenTelemetry (spec PR) and also recently stabilised in opentelemetry-java (PR).

The micrometer-otel-bridge will need updating in order to support this, and to align with the W3C spec, and bridge to OpenTelemtry's getAll(), which will be released as stable in opentelemetry-java 1.50 release within the coming days.

The Getter interface in Micrometer will need to be updated - a method to allow List<String> getAll() on top of the existing String get(). This can be a default method that just return List.of(get()) if not implemented, for backwards compatibility.

It's possible I may have missed other parts that need to be handled - if so feel free to add / correct me!

@shakuzen shakuzen added the enhancement New feature or request label May 1, 2025
@aelse-atlassian
Copy link

To help with triage/prioritisation, I see this is labeled as an enhancement but lack of this support should more correctly be noted as a bug.

The W3C baggage spec notes that multiple baggage headers are allowed. Specific examples given of header format which include this possibility.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants