Skip to content

feat(core): Emit low cardinality mcp notification span names - #23586

Merged
andreiborza merged 2 commits into
developfrom
ab/mcp-notification-span-names
Aug 26, 2026
Merged

feat(core): Emit low cardinality mcp notification span names#23586
andreiborza merged 2 commits into
developfrom
ab/mcp-notification-span-names

Conversation

@andreiborza

Copy link
Copy Markdown
Member

What

MCP notification spans now fall back to MCP notification when the message carries no method name and span streaming is enabled. Notifications with a method name keep it, and static mode is unchanged.

Why

Span names must be low cardinality when span streaming is enabled. The notification method name already matches the convention, so only the missing-method case needed the static fallback.

Closes: #23530

Comment thread packages/core/src/integrations/mcp-server/spans.ts
@andreiborza
andreiborza marked this pull request as ready for review August 25, 2026 13:51
@github-actions

github-actions Bot commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

size-limit report 📦

⚠️ Warning: Base artifact is not the latest one, because the latest workflow run is not done yet. This may lead to incorrect results. Try to re-run all tests to get up to date results.

Path Size % Change Change
@sentry/browser 28.57 kB - -
@sentry/browser - with treeshaking flags 26.92 kB - -
@sentry/browser - with treeshaking flags tracing without tracing 26.82 kB - -
@sentry/browser (incl. Tracing) 48.59 kB - -
@sentry/browser (incl. Tracing + Span Streaming) 48.6 kB - -
@sentry/browser (incl. Tracing, Profiling) 51.51 kB - -
@sentry/browser (incl. Tracing, Replay) 88.04 kB - -
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 77.45 kB - -
@sentry/browser (incl. Tracing, Replay with Canvas) 92.75 kB - -
@sentry/browser (incl. Tracing, Replay, Feedback) 105.45 kB - -
@sentry/browser (incl. Feedback) 45.81 kB - -
@sentry/browser (incl. sendFeedback) 33.36 kB - -
@sentry/browser (incl. FeedbackAsync) 38.46 kB - -
@sentry/browser (incl. Metrics) 29.51 kB - -
@sentry/browser (incl. Logs) 29.8 kB - -
@sentry/browser (incl. Metrics & Logs) 30.43 kB - -
@sentry/react 30.31 kB - -
@sentry/react (incl. Tracing) 50.8 kB - -
@sentry/vue 35.69 kB - -
@sentry/vue (incl. Tracing) 50.82 kB - -
@sentry/svelte 28.59 kB - -
CDN Bundle 30.36 kB - -
CDN Bundle (incl. Tracing) 49.06 kB - -
CDN Bundle (incl. Logs, Metrics) 32.56 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) 50.94 kB - -
CDN Bundle (incl. Replay, Logs, Metrics) 72.98 kB - -
CDN Bundle (incl. Tracing, Replay) 86.56 kB - -
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) 88.44 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) 92.34 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) 94.27 kB - -
CDN Bundle - uncompressed 89.97 kB - -
CDN Bundle (incl. Tracing) - uncompressed 146.74 kB - -
CDN Bundle (incl. Logs, Metrics) - uncompressed 96.26 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) - uncompressed 152.43 kB - -
CDN Bundle (incl. Replay, Logs, Metrics) - uncompressed 225.36 kB - -
CDN Bundle (incl. Tracing, Replay) - uncompressed 266.17 kB - -
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) - uncompressed 271.85 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 279.87 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) - uncompressed 285.53 kB - -
@sentry/nextjs (client) 53.34 kB - -
@sentry/sveltekit (client) 49.02 kB - -
@sentry/core/server 65.22 kB +0.02% +11 B 🔺
@sentry/core/browser 52.34 kB - -
@sentry/node 121.71 kB +0.02% +20 B 🔺
@sentry/node/import (ESM hook with diagnostics-channel injection) 85.18 kB - -
@sentry/node - without tracing 87.55 kB +0.03% +22 B 🔺
@sentry/aws-serverless 95.97 kB +0.03% +23 B 🔺
@sentry/cloudflare (withSentry) - minified 199.48 kB - -
@sentry/cloudflare (withSentry) 495.44 kB - -

View base workflow run

Comment thread MIGRATION.md

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.

Should be in the end state file

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Ah yes, good catch.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I also moved the already landed pageload/graphql stuff.

@andreiborza
andreiborza force-pushed the ab/mcp-notification-span-names branch from 3485246 to 7f02e2f Compare August 26, 2026 07:32

@cursor cursor Bot 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.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 7f02e2f. Configure here.

@andreiborza
andreiborza merged commit a28b354 into develop Aug 26, 2026
273 checks passed
@andreiborza
andreiborza deleted the ab/mcp-notification-span-names branch August 26, 2026 07:51
Sign up for free to 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.

Emit low cardinality mcp notification span names

2 participants