Skip to content

Commit 6e88c55

Browse files
lforstmydea
authored andcommitted
meta(v9): Add v9 migration guide (#14296)
1 parent 6772615 commit 6e88c55

File tree

2 files changed

+160
-0
lines changed

2 files changed

+160
-0
lines changed

MIGRATION.md

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ These docs walk through how to migrate our JavaScript SDKs through different maj
55
- Upgrading from [SDK 4.x to 5.x/6.x](./docs/migration/v4-to-v5_v6.md)
66
- Upgrading from [SDK 6.x to 7.x](./docs/migration/v6-to-v7.md)
77
- Upgrading from [SDK 7.x to 8.x](./MIGRATION.md#upgrading-from-7x-to-8x)
8+
- Upgrading from [SDK 8.x to 9.x](./docs/migration/v8-to-v9.md) (Work in Progress - v9 is not released yet)
89

910
# Upgrading from 7.x to 8.x
1011

docs/migration/v8-to-v9.md

+159
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,159 @@
1+
# Upgrading from 8.x to 9.x
2+
3+
**DISCLAIMER: THIS MIGRATION GUIDE IS WORK IN PROGRESS**
4+
5+
Version 9 of the Sentry SDK concerns itself with API cleanup and compatibility updates.
6+
This update contains behavioral changes that will not be caught by TypeScript or linters, so we recommend carefully reading the section on [Behavioral Changes](#2-behavior-changes).
7+
8+
Before updating to version `9.x` of the SDK, we recommend upgrading to the latest version of `8.x`.
9+
You can then go through the [Deprecations in 8.x](#deprecations-in-8x) and remove and migrate usages of deprecated APIs in your code before upgrading to `9.x`.
10+
11+
Version 9 of the JavaScript SDK is compatible with Sentry self-hosted versions 24.4.2 or higher (unchanged from last major).
12+
Lower versions may continue to work, but may not support all features.
13+
14+
## 1. Version Support Changes:
15+
16+
Version 9 of the Sentry SDK has new compatibility ranges for runtimes and frameworks.
17+
We periodically update the compatibility ranges in major versions to increase reliability and quality of APIs and instrumentation data.
18+
19+
### General Runtime Support Changes
20+
21+
**ECMAScript Version:** All of the JavaScript code in the Sentry SDK packages may now contain ECMAScript 2020 features.
22+
This includes features like Nullish Coalescing (`??`), Optional Chaining (`?.`), `String.matchAll()`, Logical Assignment Operators (`&&=`, `||=`, `??=`), and `Promise.allSettled()`.
23+
24+
If you observe failures due to syntax or features listed above, it may be an indicator that your current runtime does not support ES2020.
25+
If your runtime does not support ES2020, we recommend transpiling the SDK using Babel or similar tooling.
26+
27+
**Node.js:** The minimum supported Node.js versions are TBD, TBD, and TBD.
28+
We no longer test against Node TBD, TBD, or TBD and cannot guarantee that the SDK will work as expected on these versions.
29+
30+
**Browsers:** Due to SDK code now including ES2020 features, the minimum supported browser list now looks as follows:
31+
32+
- Chrome 80
33+
- Edge 80
34+
- Safari 14, iOS Safari 14.4
35+
- Firefox 74
36+
- Opera 67
37+
- Samsung Internet 13.0
38+
39+
If you need to support older browsers, we recommend transpiling your code using Babel or similar tooling.
40+
41+
### Framework Support Changes
42+
43+
**Angular:** TBD
44+
45+
**Ember:** TBD
46+
47+
**Next.js:** TBD
48+
49+
**Nuxt:** TBD
50+
51+
**React:** TBD
52+
53+
**Vue:** TBD
54+
55+
**Astro:** TBD
56+
57+
**Gatsby:** TBD
58+
59+
**NestJS:** TBD
60+
61+
**Svelte:** TBD
62+
63+
**SvelteKit:** TBD
64+
65+
**Bun:** TBD
66+
67+
**Cloudflare Workers:** TBD
68+
69+
**Deno:** TBD
70+
71+
**Solid:** TBD
72+
73+
**SolidStart:** TBD
74+
75+
**GCP Functions:** TBD
76+
77+
**AWS Lambda:** TBD
78+
79+
## 2. Behavior Changes
80+
81+
- Next.js withSentryConfig returning Promise
82+
- `request` on sdk processing metadata will be ignored going forward
83+
- respect sourcemap generation settings
84+
- SDK init options undefined
85+
- no more polyfills
86+
- no more update spans in vue component tracking by default
87+
- new propagation context
88+
- Client & Scope renaming
89+
90+
## 3. Package Removals
91+
92+
As part of an architectural cleanup we deprecated the following packages:
93+
94+
- `@sentry/utils`
95+
- `@sentry/types`
96+
97+
All of these packages exports and APIs have been moved into the `@sentry/core` package.
98+
99+
The `@sentry/utils` package will no longer be published.
100+
101+
The `@sentry/types` package will continue to be published but it is deprecated and we don't plan on extending its APi.
102+
You may experience slight compatibility issues in the future by using it.
103+
We decided to keep this package around to temporarily lessen the upgrade burden.
104+
It will be removed in a future major version.
105+
106+
## 4. Removal of Deprecated APIs
107+
108+
- [General](#general)
109+
- [Server-side SDKs (Node, Deno, Bun, ...)](#server-side-sdks-node-deno-bun-)
110+
- [Next.js SDK](#nextjs-sdk)
111+
- [Vue/Nuxt SDK](#vuenuxt-sdk)
112+
113+
### General
114+
115+
- sessionTimingIntegration
116+
- debugIntegration
117+
- `Request` type
118+
- spanid on propagation context
119+
- makeFifoCache in utils
120+
121+
### Server-side SDKs (Node, Deno, Bun, ...)
122+
123+
- processThreadBreadcrumbIntegration
124+
- NestJS stuff in Node sdk
125+
- various NestJS APIs
126+
- NestJS `@WithSentry`
127+
- `AddRequestDataToEventOptions.transaction`
128+
129+
### Next.js SDK
130+
131+
- `experimental_captureRequestError`
132+
133+
### Vue/Nuxt SDK
134+
135+
- vueComponent tracking options
136+
137+
## 5. Build Changes
138+
139+
Previously the CJS versions of the SDK code (wrongfully) contained compatibility statements for default exports in ESM:
140+
141+
```js
142+
Object.defineProperty(exports, '__esModule', { value: true });
143+
```
144+
145+
The SDK no longer contains these statements.
146+
Let us know if this is causing issues in your setup by opening an issue on GitHub.
147+
148+
# Deprecations in 8.x
149+
150+
TBD (Copy over from migrations list we collected)
151+
152+
# No Version Support Timeline
153+
154+
Version support timelines are stressful for anybody using the SDK, so we won't be defining one.
155+
Instead, we will be applying bug fixes and features to older versions as long as there is demand for them.
156+
We also hold ourselves to high standards security-wise, meaning that if any vulnerabilities are found, we will in almost all cases backport them.
157+
158+
Note, that we will decide on a case-per-case basis, what gets backported or not.
159+
If you need a fix or feature in a previous version of the SDK, feel free to reach out via a GitHub issue.

0 commit comments

Comments
 (0)