Skip to content

Propagation - Getter handling of multi-value headers/attributes #433

@tylerbenson

Description

@tylerbenson

Some formats (http) allow for a single key to return multiple values. This is used in w3c trace-context which we plan to support:

Tracestate MAY be sent or received as multiple header fields. ... The tracestate header SHOULD be sent as a single field when possible, but MAY be split into multiple header fields.

We don't currently specify this requirement in our spec:
https://github.com/open-telemetry/opentelemetry-specification/blob/master/specification/api-propagators.md#getter-argument

As a consequence, we aren't handling that well in java, and likely other languages:
https://github.com/open-telemetry/opentelemetry-java/blob/v0.2.x/api/src/main/java/io/opentelemetry/context/propagation/HttpTextFormat.java#L123

How do we want to handle this? Should we push responsibility for joining them properly to the Getter, or should the API support returning multiple values?

Metadata

Metadata

Labels

release:after-gaNot required before GA release, and not going to work on before GAspec:contextRelated to the specification/context directorytriage:accepted:ready-with-sponsorReady to be implemented and has a specification sponsor assigned

Type

No type

Projects

Status

Spec - Closed

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions