Skip to content

ref(node): Log when incoming request bodies are being captured #16104

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

Merged
merged 2 commits into from
Apr 22, 2025

Conversation

mydea
Copy link
Member

@mydea mydea commented Apr 22, 2025

We used to swallow most things when we try to capture request bodies of incoming requests in node. This can make it hard to debug this.

This PR adds some log messages here:

  1. Logs when we successfully patched request.on
  2. Logs the errors that happen during patching

ref #16090

@mydea mydea requested review from Lms24 and chargome April 22, 2025 08:55
@mydea mydea self-assigned this Apr 22, 2025
Copy link
Contributor

size-limit report 📦

Path Size % Change Change
@sentry/browser 23.28 KB - -
@sentry/browser - with treeshaking flags 23.12 KB - -
@sentry/browser (incl. Tracing) 36.99 KB - -
@sentry/browser (incl. Tracing, Replay) 74.17 KB - -
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 67.55 KB - -
@sentry/browser (incl. Tracing, Replay with Canvas) 78.83 KB - -
@sentry/browser (incl. Tracing, Replay, Feedback) 90.65 KB - -
@sentry/browser (incl. Feedback) 39.68 KB - -
@sentry/browser (incl. sendFeedback) 27.9 KB - -
@sentry/browser (incl. FeedbackAsync) 32.67 KB - -
@sentry/react 25.09 KB - -
@sentry/react (incl. Tracing) 38.91 KB - -
@sentry/vue 27.51 KB - -
@sentry/vue (incl. Tracing) 38.71 KB - -
@sentry/svelte 23.32 KB - -
CDN Bundle 24.51 KB - -
CDN Bundle (incl. Tracing) 36.98 KB - -
CDN Bundle (incl. Tracing, Replay) 72.03 KB - -
CDN Bundle (incl. Tracing, Replay, Feedback) 77.18 KB - -
CDN Bundle - uncompressed 71.47 KB - -
CDN Bundle (incl. Tracing) - uncompressed 109.34 KB - -
CDN Bundle (incl. Tracing, Replay) - uncompressed 220.63 KB - -
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 233.16 KB - -
@sentry/nextjs (client) 40.53 KB - -
@sentry/sveltekit (client) 37.44 KB - -
@sentry/node 143.38 KB +0.04% +51 B 🔺
@sentry/node - without tracing 96.52 KB +0.05% +48 B 🔺
@sentry/aws-serverless 120.84 KB +0.06% +62 B 🔺

View base workflow run

@mydea mydea merged commit 1d10238 into develop Apr 22, 2025
109 checks passed
@mydea mydea deleted the fn/node-bodies-log branch April 22, 2025 09:15
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.

2 participants