Skip to content

feat(node)!: Remove init, preload entry points and preloadOpenTelemetry - #23074

Open
andreiborza wants to merge 1 commit into
developfrom
ab/clean-up-node-submodule-exports
Open

feat(node)!: Remove init, preload entry points and preloadOpenTelemetry#23074
andreiborza wants to merge 1 commit into
developfrom
ab/clean-up-node-submodule-exports

Conversation

@andreiborza

@andreiborza andreiborza commented Aug 5, 2026

Copy link
Copy Markdown
Member

What

Remove the following from @sentry/node, part of the v11 major:

  • The @sentry/node/init and @sentry/node/preload no-code entry points.
  • The preloadOpenTelemetry() function.
  • The node-express-{cjs,esm}-preload e2e apps and the no-code integration suite that tested them.

Also repurposes the express/late-init integration suite (renamed to express/ignore-layers-type) into a focused ignoreLayersType test.

Why

All instrumentation is channel-based via orchestrion and is set up when the instrumented module loads, so preloading no longer does anything. preloadOpenTelemetry() could only ever preload the Sentry HTTP breadcrumb/propagation instrument, which normal init() already sets up, so it had quietly stopped doing its advertised job.

The issue proposed deprecating init/preload, but since develop is the v11 line a deprecation cycle buys nothing, so these are removed outright. @sentry/node/import stays as the one supported hook. @sentry/node/loader and @sentry/node/auto-diagnostic-channels from the issue are already moot: /loader was removed with the iitm cleanup, and /import already is the orchestrion diagnostics-channel hook that /auto-diagnostic-channels was meant to become.

The late-init suite existed to guard lazy Express option loading via a later init(), a mechanism that now lives only in @sentry/core's patchLayer (Deno-only, unit-tested) and is unreachable in node under orchestrion. It was also the only node e2e test exercising ignoreLayersType, so it is kept and refocused on that option rather than deleted.

Closes: #21483

@andreiborza

andreiborza commented Aug 5, 2026

Copy link
Copy Markdown
Member Author

buglitzer moch

@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

size-limit report 📦

Path Size % Change Change
@sentry/browser 30.12 kB - -
@sentry/browser - with treeshaking flags 28.32 kB - -
@sentry/browser (incl. Tracing) 47.53 kB - -
@sentry/browser (incl. Tracing + Span Streaming) 47.54 kB - -
@sentry/browser (incl. Tracing, Profiling) 52.29 kB - -
@sentry/browser (incl. Tracing, Replay) 86.91 kB - -
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 76.33 kB - -
@sentry/browser (incl. Tracing, Replay with Canvas) 91.6 kB - -
@sentry/browser (incl. Tracing, Replay, Feedback) 104.25 kB - -
@sentry/browser (incl. Feedback) 47.45 kB - -
@sentry/browser (incl. sendFeedback) 34.96 kB - -
@sentry/browser (incl. FeedbackAsync) 40.1 kB - -
@sentry/browser (incl. Metrics) 31.2 kB - -
@sentry/browser (incl. Logs) 31.41 kB - -
@sentry/browser (incl. Metrics & Logs) 32.11 kB - -
@sentry/react 31.93 kB - -
@sentry/react (incl. Tracing) 49.79 kB - -
@sentry/vue 35.2 kB - -
@sentry/vue (incl. Tracing) 49.51 kB - -
@sentry/svelte 30.14 kB - -
CDN Bundle 32.13 kB - -
CDN Bundle (incl. Tracing) 47.81 kB - -
CDN Bundle (incl. Logs, Metrics) 33.67 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) 49.19 kB - -
CDN Bundle (incl. Replay, Logs, Metrics) 73.02 kB - -
CDN Bundle (incl. Tracing, Replay) 85.45 kB - -
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) 86.77 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) 91.27 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) 92.59 kB - -
CDN Bundle - uncompressed 95.27 kB - -
CDN Bundle (incl. Tracing) - uncompressed 142.78 kB - -
CDN Bundle (incl. Logs, Metrics) - uncompressed 99.9 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) - uncompressed 146.75 kB - -
CDN Bundle (incl. Replay, Logs, Metrics) - uncompressed 224.6 kB - -
CDN Bundle (incl. Tracing, Replay) - uncompressed 262.03 kB - -
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) - uncompressed 266 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 275.74 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) - uncompressed 279.69 kB - -
@sentry/nextjs (client) 52.36 kB - -
@sentry/sveltekit (client) 47.99 kB - -
@sentry/core/server 65.54 kB - -
@sentry/core/browser 51.82 kB - -
@sentry/node 120.44 kB -0.02% -18 B 🔽
@sentry/node/import (ESM hook with diagnostics-channel injection) 0 B added added
@sentry/node - without tracing 84.09 kB -0.03% -24 B 🔽
@sentry/aws-serverless 92.59 kB -0.02% -14 B 🔽
@sentry/cloudflare (withSentry) - minified 217.81 kB - -
@sentry/cloudflare (withSentry) 537.06 kB - -

View base workflow run

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit 56dbdfd. Configure here.

@andreiborza
andreiborza marked this pull request as ready for review August 5, 2026 18:06
@andreiborza
andreiborza requested review from a team as code owners August 5, 2026 18:06
@andreiborza
andreiborza requested review from JPeer264, Lms24, chargome, mydea and nicohrubec and removed request for a team and mydea August 5, 2026 18:06
…lemetry`

Removes the `@sentry/node/init` and `@sentry/node/preload` no-code entry
points and the `preloadOpenTelemetry()` function. All instrumentation is
channel-based via orchestrion and set up when the instrumented module loads,
so preloading no longer does anything.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@andreiborza
andreiborza force-pushed the ab/clean-up-node-submodule-exports branch from 56dbdfd to 58d24fe Compare August 5, 2026 18:11
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.

clean up @sentry/node submodule exports

1 participant