[Bug]: duplicate header values through psr/http-message
& psr/http-client
with curl
#3132
Labels
🐛 bug
Something isn't working
Uh oh!
There was an error while loading. Please reload this page.
Bug report
When a request is comes in from RUM, the headers
x-datadog-<x>
are added already on the request.When such a request is reused & forwarded to a next service, those headers will still be there.
However, when the request is used and converted to a curl call to the next service, the datadog context values are added again, creating a comma separated header value with duplicate values.
Example:

The next service then tries to parse these headers but fails and creates a new trace root.
Given that the tracing should mostly require no code changes to codebases, I would assume we shouldn't have to strip these headers ourselves to ensure a smooth tracing.
Would it be a fix to replace these header values instead of appending them?
Thanks!
PHP version
8.3
Tracer or profiler version
1.5.1
Installed extensions
No response
Output of
phpinfo()
No response
Upgrading from
No response
The text was updated successfully, but these errors were encountered: