Uh oh!
There was an error while loading. Please reload this page.
feat(server-utils): Migrate @opentelemetry/instrumentation-ioredis to orchestrion - #21849
Conversation
Resolve conflict in experimentalUseDiagnosticsChannelInjection.ts: keep develop's derive-from-names for the 1:1 channel replacements (mysql, lru-memoizer) and add ioredisChannelIntegration separately, kept out of replacedOtelIntegrationNames since it only supersedes the ioredis sub-part of the composite OTel 'Redis'. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…rvives bundling ioredis' connect() calls standard-as-callback's CJS default export; left external it resolves to a non-function in the nitro/Rollup bundle. Inline it alongside ioredis so the interop links consistently. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
chargome
commented
Jun 30, 2026
bugbot run |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
- Keep the OTel ioredis monkey-patch on Node without tracingChannel (<18.19) even when injection is opted in, since orchestrion can't run there — otherwise ioredis <5.11.0 would lose tracing entirely. - Defer the orchestrion ioredis bindTracingChannelToSpan calls via waitForTracingChannelBinding, matching the native redis diagnostics-channel subscriber, so the async-context binding registered by initOpenTelemetry() is available before binding. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
chargome
commented
Jun 30, 2026
bugbot run |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
…nstrumentation The orchestrion opt-in imports cacheResponseHook; importing it from redis/index transitively pulled the vendored OTel IORedisInstrumentation/RedisInstrumentation into the opt-in module graph. Move cacheResponseHook + _redisOptions into redis/cache.ts (no OTel instrumentation imports) so apps using injection only for mysql/lru-memoizer don't bundle the redis OTel instrumentation. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
chargome
commented
Jun 30, 2026
bugbot run |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit da258e2. Configure here.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit da258e2. Configure here.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
develop now runs all node-integration tests a second time with INJECT_ORCHESTRION (#21911). Under orchestrion, ioredis <5.11 is instrumented by the diagnostics-channel subscriber, so its span origin is 'auto.db.orchestrion.redis' instead of the OTel monkey-patch's 'auto.db.otel.redis'. Branch the expected ioredis origin on isOrchestrionEnabled(); node-redis (redis-4/redis-5) is not ported and keeps the OTel origin. All other span attributes are identical. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
4509095 to
b755ca1Compare…rion # Conflicts: # packages/node/src/sdk/experimentalUseDiagnosticsChannelInjection.ts # packages/server-utils/src/orchestrion/channels.ts # packages/server-utils/src/orchestrion/config.ts # packages/server-utils/src/orchestrion/index.ts
…rion # Conflicts: # packages/server-utils/src/orchestrion/config.ts # packages/server-utils/src/orchestrion/index.ts
Uh oh!
There was an error while loading. Please reload this page.
…rion # Conflicts: # packages/server-utils/src/orchestrion/index.ts
Uh oh!
There was an error while loading. Please reload this page.
… orchestrion (#21925) Migrates `node-redis` from the OTel monkey-patch to orchestrion diagnostics-channel injection. Builds on the ioredis migration (#21849). - New `RedisChannel` subscriber in `@sentry/server-utils` produces the same db spans as the OTel `RedisInstrumentation`: single commands, `connect`, and multi/pipeline batches. - Batch spans mirror the native `node-redis:batch` shape. - node-redis ≥5.12 keeps using its own `node-redis:*` diagnostics_channel (unchanged). - When diagnostics-channel injection is opted in, the OTel `RedisInstrumentation` monkey-patch is fully gated off; the composite `Redis` integration stays for the native-channel subscriber/ Note: When we eventually delete the OTel Redis integration, we need to move the native diagnostics-channel subscriber (`subscribeRedisDiagnosticChannels`, for node-redis ≥5.12 / ioredis ≥5.11) into the orchestrion-owned side so it keeps running, then collapse everything into one default `Redis` integration. closes#20765 --------- Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

Migrates ioredis instrumentation from the otel to orchestrion diagnostics-channel injection.
<5.11.0;>=5.11.0keeps using ioredis' ownioredis:*diagnostics_channel (unchanged).@sentry/server-utilsproduces the same db spans as before with raw args redacted via the shareddefaultDbStatementSerializer.Redisintegration stays in place (it still handles node-redis and ioredis ≥5.11) — only its ioredis monkey-patch is turned off when injection is on, except on Node<18.19, where orchestrion isn't available.closes#20755