Skip to content

fix(server-utils): Dedupe ioredis orchestrion span for offline-queued commands - #22279

Merged
chargome merged 1 commit into
developfrom
cg/fix-ioredis-orchestrion-duplicate-span
Jul 15, 2026
Merged

fix(server-utils): Dedupe ioredis orchestrion span for offline-queued commands#22279
chargome merged 1 commit into
developfrom
cg/fix-ioredis-orchestrion-duplicate-span

Conversation

@chargome

Copy link
Copy Markdown
Member

Offline commands that were drained on connect produced duplicated spans, which we now prevent by just deduping in a WeakSet.

Saw this when testing locally, this was not catched by e2e before.

@chargomechargome self-assigned this Jul 15, 2026
@github-actions

Copy link
Copy Markdown
Contributor

size-limit report 📦

PathSize% ChangeChange
@sentry/browser27.65 kB--
@sentry/browser - with treeshaking flags26.1 kB--
@sentry/browser (incl. Tracing)46.42 kB--
@sentry/browser (incl. Tracing + Span Streaming)48.21 kB--
@sentry/browser (incl. Tracing, Profiling)51.2 kB--
@sentry/browser (incl. Tracing, Replay)85.67 kB--
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags75.31 kB--
@sentry/browser (incl. Tracing, Replay with Canvas)90.38 kB--
@sentry/browser (incl. Tracing, Replay, Feedback)103.04 kB--
@sentry/browser (incl. Feedback)44.83 kB--
@sentry/browser (incl. sendFeedback)32.45 kB--
@sentry/browser (incl. FeedbackAsync)37.58 kB--
@sentry/browser (incl. Metrics)28.74 kB--
@sentry/browser (incl. Logs)28.98 kB--
@sentry/browser (incl. Metrics & Logs)29.67 kB--
@sentry/react29.45 kB--
@sentry/react (incl. Tracing)48.68 kB--
@sentry/vue33.08 kB--
@sentry/vue (incl. Tracing)48.4 kB--
@sentry/svelte27.67 kB--
CDN Bundle30.05 kB--
CDN Bundle (incl. Tracing)48.41 kB--
CDN Bundle (incl. Logs, Metrics)31.64 kB--
CDN Bundle (incl. Tracing, Logs, Metrics)49.71 kB--
CDN Bundle (incl. Replay, Logs, Metrics)70.87 kB--
CDN Bundle (incl. Tracing, Replay)85.9 kB--
CDN Bundle (incl. Tracing, Replay, Logs, Metrics)87.21 kB--
CDN Bundle (incl. Tracing, Replay, Feedback)91.7 kB--
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics)92.97 kB--
CDN Bundle - uncompressed89.58 kB--
CDN Bundle (incl. Tracing) - uncompressed146.33 kB--
CDN Bundle (incl. Logs, Metrics) - uncompressed94.29 kB--
CDN Bundle (incl. Tracing, Logs, Metrics) - uncompressed150.31 kB--
CDN Bundle (incl. Replay, Logs, Metrics) - uncompressed219.02 kB--
CDN Bundle (incl. Tracing, Replay) - uncompressed265.54 kB--
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) - uncompressed269.5 kB--
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed279.24 kB--
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) - uncompressed283.19 kB--
@sentry/nextjs (client)51.22 kB--
@sentry/sveltekit (client)46.86 kB--
@sentry/core/server78.51 kB--
@sentry/core/browser64.86 kB--
@sentry/node-core62.79 kB-0.01%-2 B 🔽
@sentry/node125.2 kB-0.01%-1 B 🔽
@sentry/node (incl. diagnostics channel injection)140.26 kB+0.02%+27 B 🔺
@sentry/node/import (ESM hook with diagnostics-channel injection)69.96 kB--
@sentry/node/light50.8 kB-0.01%-1 B 🔽
@sentry/node - without tracing74.17 kB-0.01%-1 B 🔽
@sentry/aws-serverless83.38 kB-0.01%-4 B 🔽
@sentry/cloudflare (withSentry) - minified181.79 kB--
@sentry/cloudflare (withSentry)449.98 kB--

View base workflow run

@chargome

Copy link
Copy Markdown
MemberAuthor

bugbot run

@cursorcursorBot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ 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 fe8d7b2. Configure here.

@chargome
chargome marked this pull request as ready for review July 15, 2026 09:39
@chargome
chargome requested a review from a team as a code ownerJuly 15, 2026 09:39
@chargome
chargome requested review from logaretm, mydea and nicohrubec and removed request for a teamJuly 15, 2026 09:39

@nicohrubecnicohrubec left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice


// Each command maps to exactly one span (no offline-queue duplicate).
const setSpans = spans.filter(span => span.description === 'set test-key [1 other arguments]');
expect(setSpans).toHaveLength(1);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does this already trigger this case?

waitForTracingChannelBinding(() => {
bindTracingChannelToSpan(
commandChannel,
data => {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all of this is just refactored to startIORedisCommandSpan right?

@chargome
chargome merged commit 00df5fc into developJul 15, 2026
223 checks passed
@chargome
chargome deleted the cg/fix-ioredis-orchestrion-duplicate-span branch July 15, 2026 14:21
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@chargome@nicohrubec