Skip to content

Conversation

@andreiborza
Copy link
Member

@andreiborza andreiborza commented Dec 15, 2025

This PR adds a lightweight version of the node-core SDK that doesn't include nor requires OpenTelemetry dependencies. It provides a basic error-tracking SDK with support for request isolation via AsyncLocalStorage and basic tracing abilities
via our Sentry.startSpan* apis.

Request isolation requires Node 22.12.0+. On lower Node versions, manual wrapping via Sentry.withIsolationScope is necessary to isolate requests.

@github-actions
Copy link
Contributor

github-actions bot commented Dec 15, 2025

node-overhead report 🧳

Note: This is a synthetic benchmark with a minimal express app and does not necessarily reflect the real-world performance impact in an application.
⚠️ Warning: Base artifact is not the latest one, because the latest workflow run is not done yet. This may lead to incorrect results. Try to re-run all tests to get up to date results.

Scenario Requests/s % of Baseline Prev. Requests/s Change %
GET Baseline 8,899 - 8,923 -0%
GET With Sentry 1,750 20% 1,675 +4%
GET With Sentry (error only) 5,978 67% 6,002 -0%
POST Baseline 1,202 - 1,168 +3%
POST With Sentry 580 48% 564 +3%
POST With Sentry (error only) 1,060 88% 1,031 +3%
MYSQL Baseline 3,247 - 3,181 +2%
MYSQL With Sentry 481 15% 393 +22%
MYSQL With Sentry (error only) 2,647 82% 2,646 +0%

View base workflow run

@andreiborza andreiborza force-pushed the ab/node-core-light branch 5 times, most recently from 1687319 to 773cb0a Compare December 18, 2025 14:47
@andreiborza andreiborza force-pushed the ab/node-core-light branch 2 times, most recently from 5f3ebcb to f5bdfc9 Compare January 27, 2026 11:26
@github-actions
Copy link
Contributor

github-actions bot commented Jan 28, 2026

size-limit report 📦

⚠️ Warning: Base artifact is not the latest one, because the latest workflow run is not done yet. This may lead to incorrect results. Try to re-run all tests to get up to date results.

Path Size % Change Change
@sentry/browser 25.4 kB - -
@sentry/browser - with treeshaking flags 23.85 kB - -
@sentry/browser (incl. Tracing) 42.21 kB - -
@sentry/browser (incl. Tracing, Profiling) 46.85 kB - -
@sentry/browser (incl. Tracing, Replay) 80.83 kB - -
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 70.44 kB - -
@sentry/browser (incl. Tracing, Replay with Canvas) 85.54 kB - -
@sentry/browser (incl. Tracing, Replay, Feedback) 97.73 kB - -
@sentry/browser (incl. Feedback) 42.12 kB - -
@sentry/browser (incl. sendFeedback) 30.09 kB - -
@sentry/browser (incl. FeedbackAsync) 35.08 kB - -
@sentry/browser (incl. Metrics) 26.5 kB - -
@sentry/browser (incl. Logs) 26.66 kB - -
@sentry/browser (incl. Metrics & Logs) 27.32 kB - -
@sentry/react 27.13 kB - -
@sentry/react (incl. Tracing) 44.45 kB - -
@sentry/vue 29.83 kB - -
@sentry/vue (incl. Tracing) 44 kB - -
@sentry/svelte 25.41 kB - -
CDN Bundle 27.94 kB - -
CDN Bundle (incl. Tracing) 42.98 kB - -
CDN Bundle (incl. Logs, Metrics) 28.78 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) 43.8 kB - -
CDN Bundle (incl. Replay, Logs, Metrics) 67.72 kB - -
CDN Bundle (incl. Tracing, Replay) 79.71 kB - -
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) 80.58 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) 85.16 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) 86.09 kB - -
CDN Bundle - uncompressed 81.73 kB - -
CDN Bundle (incl. Tracing) - uncompressed 127.27 kB - -
CDN Bundle (incl. Logs, Metrics) - uncompressed 84.56 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) - uncompressed 130.1 kB - -
CDN Bundle (incl. Replay, Logs, Metrics) - uncompressed 207.94 kB - -
CDN Bundle (incl. Tracing, Replay) - uncompressed 243.87 kB - -
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) - uncompressed 246.69 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 256.67 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) - uncompressed 259.48 kB - -
@sentry/nextjs (client) 46.8 kB - -
@sentry/sveltekit (client) 42.58 kB - -
@sentry/node-core 52.16 kB +0.02% +8 B 🔺
@sentry/node 166.17 kB +0.01% +10 B 🔺
@sentry/node - without tracing 93.93 kB +0.02% +13 B 🔺
@sentry/aws-serverless 109.45 kB +0.02% +11 B 🔺

View base workflow run

@andreiborza andreiborza force-pushed the ab/node-core-light branch 3 times, most recently from 748eb5f to fdb1403 Compare January 30, 2026 15:05
@github-actions
Copy link
Contributor

github-actions bot commented Jan 30, 2026

Codecov Results 📊


Generated by Codecov Action

"dependencies": {
"@apm-js-collab/tracing-hooks": "^0.3.1",
"@sentry/core": "10.38.0",
"@sentry/opentelemetry": "10.38.0",
Copy link
Member Author

Choose a reason for hiding this comment

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

Technically, this is a breaking change. That being said, the only place where we document node-core is in the README and the README already advised users to install @sentry/opentelemetry so... maaaybe this is ok?

## Installation
```bash
npm install @sentry/node-core @sentry/opentelemetry @opentelemetry/api @opentelemetry/core @opentelemetry/context-async-hooks @opentelemetry/instrumentation @opentelemetry/resources @opentelemetry/sdk-trace-base @opentelemetry/semantic-conventions
# Or yarn
yarn add @sentry/node-core @sentry/opentelemetry @opentelemetry/api @opentelemetry/core @opentelemetry/context-async-hooks @opentelemetry/instrumentation @opentelemetry/resources @opentelemetry/sdk-trace-base @opentelemetry/semantic-conventions
```

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