feat(opentelemetry)!: Remove SentrySpanProcessor & SentrySampler#22557
Conversation
SentrySpanProcessor & SentrySamplerSentrySpanProcessor & SentrySampler
| export { wrapContextManagerClass } from './contextManager'; | ||
|
|
||
| export { SentryPropagator, shouldPropagateTraceForUrl } from './propagator'; | ||
| export { SentrySpanProcessor } from './spanProcessor'; |
There was a problem hiding this comment.
Public APIs removed without deprecation
High Severity
This removes public exports and options (SentrySpanProcessor, SentrySampler, wrapSamplingDecision, validateOpenTelemetrySetup, openTelemetrySpanProcessors, openTelemetryBasicTracerProvider, openTelemetryInstrumentations) in a non-major release without deprecation notices. Existing custom OpenTelemetry setups that import these will break at compile or runtime.
Additional Locations (2)
Triggered by project rule: PR Review Guidelines for Cursor Bot
Reviewed by Cursor Bugbot for commit a6425a2. Configure here.
bd70561 to
29be8c9
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
There are 2 total unresolved issues (including 1 from previous review).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 29be8c9. Configure here.
size-limit report 📦
|
11fa52b to
0905bde
Compare
0905bde to
f9af65e
Compare
f9af65e to
7bcf030
Compare
andreiborza
left a comment
There was a problem hiding this comment.
Could you add two entries in https://github.com/getsentry/sentry-javascript/blob/develop/MIGRATION.md#sentryopentelemetry please?
| "@opentelemetry/api": "^1.9.1", | ||
| "@opentelemetry/core": "^2.9.0", | ||
| "@opentelemetry/instrumentation": "^0.220.0", | ||
| "@opentelemetry/sdk-trace-base": "^2.9.0", |
|
For completeness: we talked about this, we do not need a full list of changes/migrations for the opentelemetry package because this will go away anyhow. |




This PR removes the
SentrySpanProcessorandSentrySampler, as well as related options in Node SDKs.Main removals
This removes the
SentrySpanProcessor(and with it, theSentryExporterwhich was used by it) as well as theSentrySampler. With this, it no longer becomes possible to do a custom otel setup (like it used to be, this will work differently going forward), so related tests are removed. This also removes the@opentelemetry/sdk-trace-basedependency, which is no longer needed.Removed options
The following options where related only to the span processor and are thus removed:
maxSpanWaitDurationopenTelemetryInstrumentationsopenTelemetrySpanProcessorsopenTelemetryBasicTracerProviderOther removals
Other, less important things that are removed:
validateOpenTelemetrySetupwrapSamplingDecisionImportantly, the context manager and propagator remain for now.