-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
[node] Distributed Tracing not working on Express server running Apollo Federation #8314
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
Comments
Hey @sergiosentry - I wasn't able to reproduce this. See: https://sentry-test.sentry.io/performance/abhi-node-gateway:9769c9be5c24405f8234f8f126071ccd/?transaction=POST+%2Fgraphql I'm running the gateway service at |
@AbhiPrasad Based on that event that was linked, it seems that this was tested on node 20. |
Can we please revisit this. |
I verified that distributed tracing was working on Apollo Foundation v3 and for all Node versions. What is left to verify is Apollo Foundation v4 - but from early testing I don't see any issues. |
@AbhiPrasad can we look at the data? Can we infer what might be missing at the customer? What are the next steps to fix this? |
@danielkhan we were able to reproduce it last week with the latest changes pushed to the repo. Abhi is looking at the new examples In order to reproduce it, we added an explicit POST request using undici to the graphQL endpoint. The only difference that I can see between the example that works and the one that does not - Is that this sample is using node 20.0.0 and this sample (which does not work) is using node 18.0.0 |
Hi @AbhiPrasad! Any additional context/repro data I can provide? Thanks |
Hey @sergiosentry - assigning @onurtemizkan to work on this. |
Hi all, I have tried to trace back this problem between Node versions. And it seems the problem exists between versions I did not check the specific update that fixed it, but I suspect it's nodejs/node@aac97c2. Reproduction on Reproduction on |
Thank you @onurtemizkan. @sergiosentry let me know if this settles it. |
Update here: The customer was able to fix Distributed Tracing by manually appending the sentry-trace and baggage headers to the downstream services requests. This should be good now! Thanks all! |
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/node
SDK Version
7.54.0
Framework Version
No response
Link to Sentry event
https://sergios-test-org.sentry.io/performance/graphql-backend:11412188f8714bef8f38ee9c39ebcdf5/?project=4505321195241472&query=http.method%3APOST&referrer=performance-transaction-summary&statsPeriod=14d&transaction=POST+%2Fgraphql&unselectedSeries=p100%28%29
SDK Setup
Steps to Reproduce
Expected Result
I expect the trace to be propagated from the gateway service to the accounts service via the /graphql request
These services should then be linked in Sentry with the same trace.
There is a request made to localhost:4001/ that was not traced correctly to that downstream service
Actual Result
The trace is not propagated to the downstream service (accounts/index.js)
It seems that we are not generating spans after the request is initialized and redirected to the GraphQL service.
The text was updated successfully, but these errors were encountered: