Uh oh!
There was an error while loading. Please reload this page.
test(e2e): Add bring-your-own-OpenTelemetry test app - #23851
Conversation
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
size-limit report 📦
|
| @@ -0,0 +1,42 @@ | |||
| import './instrument'; | |||
There was a problem hiding this comment.
l/m: Not quite sure, but should we use --import for this test instead, to also make sure that import in the middle & orchestrion play together reasonably?
| dsn: process.env.E2E_TEST_DSN, | ||
| debug: !!process.env.DEBUG, | ||
| tunnel: `http://localhost:3031/`, // proxy server | ||
| tracesSampleRate: 1, |
There was a problem hiding this comment.
this is actually not correct/supported though, I think - should be tracing disabled (so this line omitted)?
There was a problem hiding this comment.
and this is missing the otlp integration?
andreiborza
commented
Sep 2, 2026
@mydea right, I update the PR to showcase sentry tracing off + otel setup + sentry otlp integration and updated the migration guide to not document a half-half kind of setup. |
| ``` | ||
| If a library you depend on emits its own OpenTelemetry spans and you want those in Sentry too, use setup 2. | ||
| Sentry owns spans end to end and there is no OpenTelemetry involved: spans created through `@opentelemetry/api` are ignored. If a library you depend on emits its own OpenTelemetry spans and you want those in Sentry too, use setup 2. |
There was a problem hiding this comment.
| Sentry owns spans end to end and there is no OpenTelemetry involved: spans created through `@opentelemetry/api` are ignored. If a library you depend on emits its own OpenTelemetry spans and you want those in Sentry too, use setup 2. | |
| Spans are completely managed by the Sentry SDK and there is no OpenTelemetry involved: spans created through `@opentelemetry/api` are ignored. If a library you depend on emits its own OpenTelemetry spans and you want those in Sentry too, use setup 2. |
| `enableOpenTelemetrySetup` already defaults to `false` on most server SDKs, so there is nothing to set. On `@sentry/nextjs` and `@sentry/sveltekit` it defaults to `true`, so you have to set it to `false` explicitly. Otherwise Sentry registers its own tracer provider and you end up in setup 2 rather than this one. | ||
| OpenTelemetry owns spans end to end. Sentry captures errors and logs, and the Sentry `otlpIntegration()` attaches them to the active OpenTelemetry span so all your telemetry is connected in one trace. `getOtlpTracesEndpoint()` turns your DSN into the URL and auth headers for Sentry's OTLP endpoint, so you can point your own exporter at Sentry, at your own collector, or at both. | ||
| OpenTelemetry owns spans end to end and the two pipelines stay separate: Sentry sends no spans, and no Sentry span is exported to your OpenTelemetry pipeline. Sentry captures errors and logs, and the Sentry `otlpIntegration()` attaches them to the active OpenTelemetry span so all your telemetry is connected in one trace. `getOtlpTracesEndpoint()` turns your DSN into the URL and auth headers for Sentry's OTLP endpoint, so you can point your own exporter at Sentry, at your own collector, or at both. |
There was a problem hiding this comment.
This sentence starts like the other one. I would either keep the "owning" verb for both or use something different here (but same as the above sentence). IDK, but "owning" seems so vague to me, or is this an established way of saying this?
Uh oh!
There was an error while loading. Please reload this page.
What
Adds a
node-otel-sdk-nodee2e app for the setup where OpenTelemetry owns tracing: the user's own@opentelemetry/sdk-nodewith Sentry tracing off andotlpIntegration(). It runs as ESM so import-in-the-middle and orchestrion are exercised together. The migration guide now presents that setup as requiring Sentry tracing off, instead of offering Sentry spans alongside your own.Why
The bring-your-own-OpenTelemetry apps named in the issue were removed together with the paths they tested (
SentrySpanProcessorin #22557, the preload entry point in #23074), so nothing covered a user owned OpenTelemetry SDK any more.Closes: #22645