Skip to content

Commit 9771d2d

Browse files
authored
Remove last references to @sentry/tracing (#6565)
1 parent 1bc4bd8 commit 9771d2d

File tree

11 files changed

+37
-50
lines changed

11 files changed

+37
-50
lines changed

src/docs/product/issues/issue-details/performance-issues/large-render-blocking-asset/index.mdx

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ A _Large Render Blocking Asset_ is a performance problem that happens when a lar
1313
The detector for this performance issue looks for specific asset (resource) spans with the following criteria:
1414

1515
- The span operation has to be either a: `resource.link` or `resource.script`.
16-
- The span's `resource.render_blocking_status` data property should either have a value of `blocking` (added by the `@sentry/tracing` SDK, version `7.38.0`), or be missing.
16+
- The span's `resource.render_blocking_status` data property should either have a value of `blocking` (added by the `@sentry/browser` SDK, version `7.38.0`), or be missing.
1717
- The span's `Encoded Body Size` data property has to be over `1MB`.
1818
- The [First Contentful Paint (FCP)](/product/performance/web-vitals/#first-contentful-paint-fcp) of the transaction must be at least `2` seconds (with an upper bound of `10` seconds to eliminate outliers).
1919
- The span's duration must be at least `33%` of the FCP.

src/platform-includes/getting-started-config/node.mdx

-10
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,6 @@ Once this is done, Sentry's Node SDK captures all transactions and unhandled exc
33
```javascript {tabTitle:ESM}
44
import * as Sentry from "@sentry/node";
55

6-
// Importing @sentry/tracing patches the global hub for tracing to work.
7-
import "@sentry/tracing";
8-
9-
// If you want to use `@sentry/tracing` in your project directly, use a named import instead:
10-
// import * as SentryTracing from "@sentry/tracing"
11-
// Unused named imports are not guaranteed to patch the global hub.
12-
136
Sentry.init({
147
dsn: "___PUBLIC_DSN___",
158

@@ -22,9 +15,6 @@ Sentry.init({
2215
```javascript {tabTitle:CommonJS}
2316
const Sentry = require("@sentry/node");
2417

25-
// Importing @sentry/tracing patches the global hub for tracing to work.
26-
const SentryTracing = require("@sentry/tracing");
27-
2818
Sentry.init({
2919
dsn: "___PUBLIC_DSN___",
3020

Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
```bash {tabTitle: ESM}
22
# Using yarn
3-
yarn add @sentry/node @sentry/tracing
3+
yarn add @sentry/node
44
# Using npm
5-
npm install --save @sentry/node @sentry/tracing
5+
npm install --save @sentry/node
66
```

src/platform-includes/performance/connect-services/node.mdx

+7-7
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,21 @@ const sentryTraceHeader = span.toTraceparent();
77

88
requestOptions.headers = {
99
...requestOptions.headers,
10-
'sentry-trace': sentryTraceHeader,
10+
"sentry-trace": sentryTraceHeader,
1111
};
1212
```
1313

14-
To create a span as a continuation of the trace retrieved from the upstream service, use `extractTraceparentData` function from `@sentry/tracing`:
14+
To create a span as a continuation of the trace retrieved from the upstream service, use `extractTraceparentData` function from `@sentry/node`:
1515

1616
```javascript
17-
import { extractTraceparentData } from "@sentry/tracing";
17+
import { extractTraceparentData } from "@sentry/node";
1818

1919
// The request headers sent by your upstream service to your backend.
20-
const traceparentData = extractTraceparentData(request.headers['sentry-trace']);
20+
const traceparentData = extractTraceparentData(request.headers["sentry-trace"]);
2121

2222
const transaction = Sentry.startTransaction({
23-
op: 'transaction_op',
24-
name: 'transaction_name',
23+
op: "transaction_op",
24+
name: "transaction_name",
2525
...traceparentData,
2626
});
27-
```
27+
```

src/platforms/common/performance/index.mdx

+1-1
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ Learn more about using and customizing the React Profiler in [React Component Tr
131131

132132
## React Router
133133

134-
If you are using `react-router`, we provide <PlatformLink to="/configuration/integrations/react-router/">React Router instrumentation</PlatformLink> to use with our `@sentry/tracing` package.
134+
If you are using `react-router`, we provide <PlatformLink to="/configuration/integrations/react-router/">React Router instrumentation</PlatformLink> to use alongside Sentry Performance Monitoring.
135135

136136
</PlatformSection>
137137

src/platforms/javascript/common/install/lazy-load-sentry.mdx

+2-3
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,8 @@ The loader script includes a call to `Sentry.init` with one configuration option
9797

9898
## **Limitations**
9999

100-
Because the loader injects the SDK asynchronously, only *unhandled errors* and *unhandled promise rejections* will be caught and buffered before the SDK is fully loaded. Specifically, the capturing of any [breadcrumb data](../../enriching-events/breadcrumbs/) will not be available until the SDK is fully loaded and initialized. To reduce the amount of time these features are unavailable, set `data-lazy="no"` or call `forceLoad()` as described above.
101-
102-
For similar reasons, the loader is not available in a form which includes either performance monitoring or release health (sessions). If you want performance monitoring, including pageload times, you can [bundle both `@sentry/browser` and `@sentry/tracing` with your app](../npm) or use our CDN, specifically the [bundle that includes tracing features](../cdn/#performance-bundle). For release health, bundling is the only option, though no additional package is needed.
100+
Because the loader injects the SDK asynchronously, only _unhandled errors_ and _unhandled promise rejections_ will be caught and buffered before the SDK is fully loaded. Specifically, the capturing of any [breadcrumb data](../../enriching-events/breadcrumbs/) will not be available until the SDK is fully loaded and initialized. To reduce the amount of time these features are unavailable, set `data-lazy="no"` or call `forceLoad()` as described above.
103101

102+
For similar reasons, the loader is not available in a form which includes either performance monitoring or release health (sessions). If you want performance monitoring, including pageload times, you can [our NPM package](../npm) or use our CDN, specifically the [bundle that includes tracing features](../cdn/#performance-bundle). For release health, bundling is the only option, though no additional package is needed.
104103

105104
If you want to understand the inner workings of the loader itself, you can read the documented source code in all its glory over at the [sentry-javascript repository](https://github.com/getsentry/sentry-javascript/blob/master/packages/browser/src/loader.js).

src/wizard/javascript/react/with-error-monitoring-and-performance.md

+9-6
Original file line numberDiff line numberDiff line change
@@ -3,33 +3,33 @@ name: React
33
doc_link: https://docs.sentry.io/platforms/javascript/guides/react/
44
support_level: production
55
type: framework
6-
76
---
87

98
## Install
9+
1010
Sentry captures data by using an SDK within your application’s runtime.
1111

1212
```bash
1313
# Using yarn
14-
yarn add @sentry/react @sentry/tracing
14+
yarn add @sentry/react
1515

1616
# Using npm
17-
npm install --save @sentry/react @sentry/tracing
17+
npm install --save @sentry/react
1818
```
1919

2020
## Configure
21+
2122
Initialize Sentry as early as possible in your application's lifecycle.
2223

2324
```javascript
2425
import { createRoot } React from "react-dom/client";
25-
import React from "react";
26+
import React from "react";
2627
import * as Sentry from "@sentry/react";
27-
import { BrowserTracing } from "@sentry/tracing";
2828
import App from "./App";
2929

3030
Sentry.init({
3131
dsn: "___PUBLIC_DSN___",
32-
integrations: [new BrowserTracing()],
32+
integrations: [new Sentry.BrowserTracing()],
3333
// Performance Monitoring
3434
tracesSampleRate: 1.0, // Capture 100% of the transactions, reduce in production!
3535
});
@@ -40,14 +40,17 @@ root.render(<App />)
4040
```
4141

4242
## Verify
43+
4344
This snippet contains an intentional error and can be used as a test to make sure that everything's working as expected.
4445

4546
```javascript
4647
return <button onClick={() => methodDoesNotExist()}>Break the world</button>;
4748
```
4849

4950
---
51+
5052
## Next Steps
53+
5154
- [Source Maps](https://docs.sentry.io/platforms/javascript/guides/react/sourcemaps/): Learn how to enable readable stack traces in your Sentry errors.
5255
- [React Features](https://docs.sentry.io/platforms/javascript/guides/react/features/): Learn about our first class integration with the React framework.
5356
- [Session Replay](https://docs.sentry.io/platforms/javascript/guides/react/session-replay/): Get to the root cause of an error or latency issue faster by seeing all the technical details related to that issue in one visual replay on your web application.

src/wizard/javascript/react/with-error-monitoring-performance-and-replay.md

+9-6
Original file line numberDiff line numberDiff line change
@@ -3,33 +3,33 @@ name: React
33
doc_link: https://docs.sentry.io/platforms/javascript/guides/react/
44
support_level: production
55
type: framework
6-
76
---
87

98
## Install
9+
1010
Sentry captures data by using an SDK within your application’s runtime.
1111

1212
```bash
1313
# Using yarn
14-
yarn add @sentry/react @sentry/tracing
14+
yarn add @sentry/react
1515

1616
# Using npm
17-
npm install --save @sentry/react @sentry/tracing
17+
npm install --save @sentry/react
1818
```
1919

2020
## Configure
21+
2122
Initialize Sentry as early as possible in your application's lifecycle.
2223

2324
```javascript
2425
import { createRoot } React from "react-dom/client";
25-
import React from "react";
26+
import React from "react";
2627
import * as Sentry from "@sentry/react";
27-
import { BrowserTracing } from "@sentry/tracing";
2828
import App from "./App";
2929

3030
Sentry.init({
3131
dsn: "___PUBLIC_DSN___",
32-
integrations: [new BrowserTracing(), new Sentry.Replay()],
32+
integrations: [new Sentry.BrowserTracing(), new Sentry.Replay()],
3333
// Performance Monitoring
3434
tracesSampleRate: 1.0, // Capture 100% of the transactions, reduce in production!
3535
// Session Replay
@@ -43,13 +43,16 @@ root.render(<App />)
4343
```
4444

4545
## Verify
46+
4647
This snippet contains an intentional error and can be used as a test to make sure that everything's working as expected.
4748

4849
```javascript
4950
return <button onClick={() => methodDoesNotExist()}>Break the world</button>;
5051
```
5152

5253
---
54+
5355
## Next Steps
56+
5457
- [Source Maps](https://docs.sentry.io/platforms/javascript/guides/react/sourcemaps/): Learn how to enable readable stack traces in your Sentry errors.
5558
- [React Features](https://docs.sentry.io/platforms/javascript/guides/react/features/): Learn about our first class integration with the React framework.

src/wizard/node/express.md

+2-4
Original file line numberDiff line numberDiff line change
@@ -9,23 +9,21 @@ Add `@sentry/node` as a dependency:
99

1010
```bash
1111
# Using yarn
12-
yarn add @sentry/node @sentry/tracing
12+
yarn add @sentry/node
1313

1414
# Using npm
15-
npm install --save @sentry/node @sentry/tracing
15+
npm install --save @sentry/node
1616
```
1717

1818
Sentry should be initialized as early in your app as possible.
1919

2020
```javascript
2121
import express from "express";
2222
import * as Sentry from "@sentry/node";
23-
import * as Tracing from "@sentry/tracing";
2423

2524
// or using CommonJS
2625
// const express = require('express');
2726
// const Sentry = require('@sentry/node');
28-
// const Tracing = require("@sentry/tracing");
2927

3028
const app = express();
3129

src/wizard/node/index.md

+2-6
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ Add `@sentry/node` as a dependency:
99

1010
```bash
1111
# Using yarn
12-
yarn add @sentry/node @sentry/tracing
12+
yarn add @sentry/node
1313

1414
# Using npm
15-
npm install --save @sentry/node @sentry/tracing
15+
npm install --save @sentry/node
1616
```
1717

1818
You need to inform the Sentry Node SDK about your DSN:
@@ -22,10 +22,6 @@ const Sentry = require("@sentry/node");
2222
// or use es6 import statements
2323
// import * as Sentry from '@sentry/node';
2424

25-
const Tracing = require("@sentry/tracing");
26-
// or use es6 import statements
27-
// import * as Tracing from '@sentry/tracing';
28-
2925
Sentry.init({
3026
dsn: "___PUBLIC_DSN___",
3127

src/wizard/node/serverlesscloud.md

+2-4
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,21 @@ support_level: production
55
type: framework
66
---
77

8-
Add `@sentry/node` and `@sentry/tracing` as dependencies:
8+
Add `@sentry/node` as a dependency:
99

1010
```bash
11-
cloud install @sentry/node @sentry/tracing
11+
cloud install @sentry/node:
1212
```
1313

1414
Sentry should be initialized as early in your app as possible.
1515

1616
```javascript
1717
import api from "@serverless/cloud";
1818
import * as Sentry from "@sentry/node";
19-
import * as Tracing from "@sentry/tracing";
2019

2120
// or using CommonJS
2221
// const api = require("@serverless/cloud");
2322
// const Sentry = require('@sentry/node');
24-
// const Tracing = require("@sentry/tracing");
2523

2624
Sentry.init({
2725
dsn: "___PUBLIC_DSN___",

0 commit comments

Comments
 (0)