Skip to content
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

Add support for HTTP Client baggage propagation #675

Merged

Conversation

DAcodedBEAT
Copy link
Contributor

I was looking to make use of the baggage HTTP header and noticed that this wasn't added to sentry-symfony in yet.

Resolves #663

@cleptric
Copy link
Member

Thanks for the contribution.
We'll also have to update the AbstractTraceableHttpClient

https://github.com/getsentry/sentry-symfony/blob/develop/src/Tracing/HttpClient/AbstractTraceableHttpClient.php#L44-L66

to actually include the baggage header on HTTP client requests. The header should only be included if the request's host matches an entry in trace_propagation_target .

Copy link
Member

@cleptric cleptric left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add an assertion for the header in the tests

public function testRequest(): void

@cleptric cleptric added this to the 4.5 milestone Nov 22, 2022
@DAcodedBEAT
Copy link
Contributor Author

Ahh totally missed this change, thanks for pointing out that unit test. I have updated this in 4321e2a

CHANGELOG.md Outdated Show resolved Hide resolved
@cleptric cleptric merged commit 38f70b7 into getsentry:develop Nov 24, 2022
@cleptric cleptric linked an issue Nov 24, 2022 that may be closed by this pull request
@DAcodedBEAT DAcodedBEAT deleted the add-trace_propagation_targets-option branch July 8, 2023 17:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add support for HTTP Client baggage propagation
2 participants