sentry-javascript
sentry-javascript copied to clipboard
chore(build): Use Rolldown
Continuation of the work done in #18065
Some bundles are seeing -10% in size reduction, while some see 15% ish. Speed benefits will only be more visible if we fully embrace rolldown and remove any JS plugins.
TODO:
- [x] Get the build working again repo wide.
- [x] Get tests to pass ensuring correct export output
- [x] Remove as many JS plugins as possible
- [x] Sucrase
- [x] Replace plugin
- [x] License
- [x] TypeScript
- [x] Terser
Blocked by:
- https://github.com/rolldown/rolldown/issues/6992
- https://github.com/rolldown/rolldown/issues/7097
- https://github.com/rolldown/rolldown/issues/7115
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.
| Scenario | Requests/s | % of Baseline | Prev. Requests/s | Change % |
|---|---|---|---|---|
| GET Baseline | 8,996 | - | 11,145 | -19% |
| GET With Sentry | 1,716 | 19% | 1,889 | -9% |
| GET With Sentry (error only) | 6,145 | 68% | 7,659 | -20% |
| POST Baseline | 1,195 | - | 1,171 | +2% |
| POST With Sentry | 590 | 49% | 582 | +1% |
| POST With Sentry (error only) | 1,056 | 88% | 1,039 | +2% |
| MYSQL Baseline | 3,257 | - | 4,024 | -19% |
| MYSQL With Sentry | 453 | 14% | 600 | -25% |
| MYSQL With Sentry (error only) | 2,672 | 82% | 3,153 | -15% |
size-limit report 📦
| Path | Size | % Change | Change |
|---|---|---|---|
| @sentry/browser | 24.69 kB | -0.54% | -132 B 🔽 |
| @sentry/browser - with treeshaking flags | 23.21 kB | -0.49% | -114 B 🔽 |
| @sentry/browser (incl. Tracing) | 41.41 kB | -0.44% | -183 B 🔽 |
| @sentry/browser (incl. Tracing, Profiling) | 45.95 kB | -0.53% | -242 B 🔽 |
| ⛔️ @sentry/browser (incl. Tracing, Replay) (max: 82 kB) | 82.73 kB | +3.2% | +2.56 kB 🔺 |
| @sentry/browser (incl. Tracing, Replay) - with treeshaking flags | 69.74 kB | -0.24% | -165 B 🔽 |
| ⛔️ @sentry/browser (incl. Tracing, Replay with Canvas) (max: 85 kB) | 104.09 kB | +22.67% | +19.23 kB 🔺 |
| ⛔️ @sentry/browser (incl. Tracing, Replay, Feedback) (max: 98 kB) | 99.84 kB | +2.83% | +2.74 kB 🔺 |
| @sentry/browser (incl. Feedback) | 41.62 kB | +0.21% | +84 B 🔺 |
| @sentry/browser (incl. sendFeedback) | 29.37 kB | -0.47% | -137 B 🔽 |
| @sentry/browser (incl. FeedbackAsync) | 34.38 kB | -0.37% | -125 B 🔽 |
| @sentry/browser (incl. Metrics) | 25.63 kB | -0.87% | -224 B 🔽 |
| @sentry/browser (incl. Logs) | 25.9 kB | -0.66% | -170 B 🔽 |
| @sentry/browser (incl. Metrics & Logs) | 26.52 kB | -0.79% | -209 B 🔽 |
| @sentry/react | 26.53 kB | -0.03% | -7 B 🔽 |
| @sentry/react (incl. Tracing) | 43.78 kB | -0.03% | -11 B 🔽 |
| @sentry/vue | 28.99 kB | -1.02% | -298 B 🔽 |
| @sentry/vue (incl. Tracing) | 43.04 kB | -0.87% | -374 B 🔽 |
| @sentry/svelte | 24.72 kB | -0.48% | -119 B 🔽 |
| ⛔️ CDN Bundle (max: 27.5 kB) | 27.98 kB | +2.66% | +724 B 🔺 |
| ⛔️ CDN Bundle (incl. Tracing) (max: 42.5 kB) | 43.03 kB | +1.86% | +785 B 🔺 |
| ⛔️ CDN Bundle (incl. Tracing, Replay) (max: 80 kB) | 82.5 kB | +4.49% | +3.54 kB 🔺 |
| ⛔️ CDN Bundle (incl. Tracing, Replay, Feedback) (max: 86 kB) | 91.57 kB | +8.49% | +7.16 kB 🔺 |
| ⛔️ CDN Bundle - uncompressed (max: 82 kB) | 83.21 kB | +3.94% | +3.15 kB 🔺 |
| ⛔️ CDN Bundle (incl. Tracing) - uncompressed (max: 127 kB) | 129.32 kB | +3.05% | +3.83 kB 🔺 |
| ⛔️ CDN Bundle (incl. Tracing, Replay) - uncompressed (max: 245 kB) | 260.08 kB | +7.47% | +18.06 kB 🔺 |
| ⛔️ CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed (max: 264 kB) | 281.83 kB | +10.62% | +27.04 kB 🔺 |
| ⛔️ @sentry/nextjs (client) (max: 46.5 kB) | 48.27 kB | +4.9% | +2.25 kB 🔺 |
| ⛔️ @sentry/sveltekit (client) (max: 42 kB) | 42.03 kB | +0.14% | +55 B 🔺 |
| ⛔️ @sentry/node-core (max: 52 kB) | 53.18 kB | +3.02% | +1.55 kB 🔺 |
| ⛔️ @sentry/node (max: 162 kB) | 162.43 kB | +0.57% | +910 B 🔺 |
| @sentry/node - without tracing | 94.75 kB | +1.83% | +1.7 kB 🔺 |
| @sentry/aws-serverless | 110.61 kB | +1.88% | +2.04 kB 🔺 |