Content-Length: 394496 | pFad | http://github.com/getsentry/sentry-javascript/pull/16732

16 feat: Add opt-in `vercelAiIntegration` to cloudflare & vercel-edge by mydea · Pull Request #16732 · getsentry/sentry-javascript · GitHub
Skip to content

feat: Add opt-in vercelAiIntegration to cloudflare & vercel-edge #16732

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 13 commits into from
Jun 26, 2025

Conversation

mydea
Copy link
Member

@mydea mydea commented Jun 25, 2025

This is on top of #16714.

This adds the vercelAiIntegration to the cloudflare SDK, as well as to the vercel-edge SDK.

I moved the critical code from node to core package, so we can reuse this (the code to process spans).

The integration is not added by default, but needs to be added manually. then it will "force" add the event processors etc. We cannot auto-detect the ai package, sadly, because this does not work in workers 😢 so for now it needs to be added manually to avoid overhead for users that don't need this.

@andreiborza let's verify that this works when deployed to cloudflare, esp. also the auto-enablement via the modules integration etc 🤔

@mydea mydea force-pushed the fn/vercel-ai-cloudflare branch 2 times, most recently from a7827af to 6b09503 Compare June 25, 2025 12:25
Copy link
Contributor

github-actions bot commented Jun 25, 2025

size-limit report 📦

Path Size % Change Change
@sentry/browser 23.99 kB - -
@sentry/browser - with treeshaking flags 23.76 kB - -
@sentry/browser (incl. Tracing) 38.84 kB - -
@sentry/browser (incl. Tracing, Replay) 76.98 kB - -
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 70.07 kB - -
@sentry/browser (incl. Tracing, Replay with Canvas) 81.74 kB - -
@sentry/browser (incl. Tracing, Replay, Feedback) 93.83 kB - -
@sentry/browser (incl. Feedback) 40.75 kB - -
@sentry/browser (incl. sendFeedback) 28.7 kB - -
@sentry/browser (incl. FeedbackAsync) 33.59 kB - -
@sentry/react 25.76 kB - -
@sentry/react (incl. Tracing) 40.84 kB - -
@sentry/vue 28.36 kB - -
@sentry/vue (incl. Tracing) 40.7 kB - -
@sentry/svelte 24.01 kB - -
CDN Bundle 25.5 kB - -
CDN Bundle (incl. Tracing) 38.92 kB - -
CDN Bundle (incl. Tracing, Replay) 74.83 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) 80.29 kB - -
CDN Bundle - uncompressed 74.5 kB - -
CDN Bundle (incl. Tracing) - uncompressed 115.42 kB - -
CDN Bundle (incl. Tracing, Replay) - uncompressed 229.47 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 242.3 kB - -
@sentry/nextjs (client) 42.47 kB - -
@sentry/sveltekit (client) 39.33 kB - -
@sentry/node 150.91 kB +0.03% +40 B 🔺
@sentry/node - without tracing 98.63 kB - -
@sentry/aws-serverless 124.4 kB +0.01% +1 B 🔺

View base workflow run

@mydea mydea force-pushed the fn/vercel-ai-cloudflare branch from 7865cc5 to 6c68d0e Compare June 26, 2025 07:45
@mydea mydea changed the title feat(cloudflare): Add vercelAiIntegration & modulesIntegration feat(cloudflare): Add opt-in vercelAiIntegration Jun 26, 2025
@mydea mydea changed the title feat(cloudflare): Add opt-in vercelAiIntegration feat: Add opt-in vercelAiIntegration to cloudflare & vercel-edge Jun 26, 2025
* This is a copy of the Vercel AI integration from the node SDK.
*
* The only difference is that it does not use `@opentelemetry/instrumentation`
* because Cloudflare Workers do not support it.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* because Cloudflare Workers do not support it.
* because vercel-edge does not support it.

@mydea mydea force-pushed the fn/vercel-ai-cloudflare branch from 45f2304 to d898309 Compare June 26, 2025 10:37
@mydea mydea merged commit 40f04bc into develop Jun 26, 2025
163 checks passed
@mydea mydea deleted the fn/vercel-ai-cloudflare branch June 26, 2025 10:57
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.

2 participants








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/getsentry/sentry-javascript/pull/16732

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy