Uh oh!
There was an error while loading. Please reload this page.
ref(node): Avoid double wrapping http module for vercel on Node - #16178
ref(node): Avoid double wrapping http module for vercel on Node#16178mydea wants to merge 3 commits into
http module for vercel on Node#16178Conversation
67ee12d to
512e319Comparesize-limit report 📦
|
72ddee3 to
596dceeComparelforst
commented
May 5, 2025
Would you mind explaining in the PR description why we do this and what this PR does? I can see us going back to this in 3 months and asking ourselves wtf |
aff551f to
0cd1834Compare512e319 to
96423b2Comparehttp module for vercel-edgehttp module for vercel on Nodelforst
commented
May 6, 2025
To recapitulate, what needs to happen for the logic to still work is to register the Findings so far, because the current approach doesn't work:
tldr we have no good place to register the |
As pre-work for #16178, actually add a test for this (kind of). This showed that there was actually a fundamental flaw here, as we looked as the `req` not the `res`, oops.
96423b2 to
8e6d77eComparemydea
commented
May 7, 2025
OK we can't get this to work on Vercel on prod, so we'll just remove this for now until we get a better handle on this 😬 cc @lforst |
lforst
commented
May 7, 2025
I am in support of removing |
mydea
commented
May 7, 2025
Replaced by #16217 |
We could never get this to apply properly on vercel in production, so we're removing this for now and may revisit this later. Replaces #16178
This PR is a follow up to #16177
There, we found out that double-wrapping (with
stealthWrap) the http module seems to break in ESM mode, for whatever reason - us double-wrapping this leads to the OTEL-instrumentation creating spans twice, for whatever reason.We removed this for the core sentry-http instrumentation, but we still do it for vercel-edge here. For consistency, this cleans this up so we should be safe.
As an added benefit, it again leads to all the sentry-specific instrumentation code to be in one place, and to us not having to care about instrumentation order, hopefully, if this actually works.