getsentry / getsentry/sentry-javascript

Automatically exclude tunnel request from backend transactions

Đang mở
#16,157 1 bình luận 1 reaction 0 người được giao Xem trên GitHub
Improvement Node.js
Ngôn ngữ chính
TypeScript
Star
8.7k
Fork
1.8k
Merge trung bình
1 ngày 17 giờ
Pull request đã merge (30 ngày)
515

Mô tả

### Problem Statement

When setting up the `tunnel` option, users will often follow [the docs](https://docs.sentry.io/platforms/javascript/troubleshooting/#using-the-tunnel-option) and add a local API route to forward those envelopes.

These POST requests will usually get auto-instrumented on the backend and will potentially result in a transaction for every frontend envelope.

### Solution Brainstorm

Filter these out in some way?

If the `tunnel` option is set in the frontend, we could automatically set the `Content-Type` as `application/x-sentry-envelope`. This can be picked up in the http instrumentation and used to ignore these requests.

- Adding the `Content-Type` header will also fix a Svelte issue #16112

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.