-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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 tunneling option to @sentry/astro #10309
Comments
Hi @florian-lefebvre thanks for writing in! So to confirm, the It sounds like a viable option to me and I like the idea of simply injecting the route. However, right now we don't have the capacity to work on this. I'll backlog it for later. If you want to contribute this feature, feel free to open a PR. I'd recommend taking a look at this PR which was supposed to add guidance on how to implement such a proxy server in Node. Unfortunately this PR got a bit stale which is why it didn't make it to docs yet (I'll follow up on this). Long story short, we'll need to parse the envelope payload and read the DSN from the envelope headers. |
Yes that's it! Assign me, I'll submit a PR today |
Question about the linked PR: what data is sent as body? Since it has to be forwarded with the fetch call, there is no |
IIRC you should forward the body as If you're curious, here's our envelope payload specification. Hope this answers your question. |
Problem Statement
I think the Next package has an option for tunneling, it would be great to have the same for Astro
Solution Brainstorm
Back when I had a look at the docs, there was a snippet with how to create a tunnel endpoint in PHP. Closest thing I find now is https://docs.sentry.io/platforms/javascript/troubleshooting/#using-the-tunnel-option.
Anyway, it seems fairly easy with the
injectRoute
utility. Here is what I've done for a project of mine:It's not always working so something is probably off. I can contribute this if you can help fix the endpoint logic itself
The text was updated successfully, but these errors were encountered: