René's URL Explorer Experiment


Title: feat(v9/core): Add shared `flushIfServerless` function (#17177) by chargome · Pull Request #17239 · getsentry/sentry-javascript · GitHub

Open Graph Title: feat(v9/core): Add shared `flushIfServerless` function (#17177) by chargome · Pull Request #17239 · getsentry/sentry-javascript

X Title: feat(v9/core): Add shared `flushIfServerless` function (#17177) by chargome · Pull Request #17239 · getsentry/sentry-javascript

Description: backports #17177

Open Graph Description: backports #17177

X Description: backports #17177

Opengraph URL: https://github.com/getsentry/sentry-javascript/pull/17239

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.113.3

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:aded9ec2-e5c3-250f-8d2b-76d546a18fd0
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idBF3C:DF8DA:266025:3499A3:6B05FD25
html-safe-nonce24a7b238a07ebb733988d7a288dfaac17d45694c5e1d9365f732b6774ddafc8f
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCRjNDOkRGOERBOjI2NjAyNTozNDk5QTM6NkIwNUZEMjUiLCJ2aXNpdG9yX2lkIjoiNDk3Mzc1NjM1NDU5NTc4MTkyNSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac1819281fdaac3e7f45f7ed0ee7832587b6206330eca9ad762e5d7d5edb07efc0
hovercard-subject-tagpull_request:2709535304
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/getsentry/sentry-javascript/pull/17239/files
twitter:imagehttps://avatars.githubusercontent.com/u/20254395?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/20254395?s=400&v=4
og:image:altbackports #17177
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Nonec214754a6652274794ed4e054a7b71be999d69843f103ba54893001d45010ece
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/getsentry/sentry-javascript git https://github.com/getsentry/sentry-javascript.git
octolytics-dimension-user_id1396951
octolytics-dimension-user_logingetsentry
octolytics-dimension-repository_id3328572
octolytics-dimension-repository_nwogetsentry/sentry-javascript
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id3328572
octolytics-dimension-repository_network_root_nwogetsentry/sentry-javascript
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release7d164a4e71eb333b2b17fd5b17e18efb7855505c
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/getsentry/sentry-javascript/pull/17239/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgetsentry%2Fsentry-javascript%2Fpull%2F17239%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgetsentry%2Fsentry-javascript%2Fpull%2F17239%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=getsentry%2Fsentry-javascript
Reloadhttps://github.com/getsentry/sentry-javascript/pull/17239/files
Reloadhttps://github.com/getsentry/sentry-javascript/pull/17239/files
Reloadhttps://github.com/getsentry/sentry-javascript/pull/17239/files
getsentryhttps://github.com/getsentry
sentry-javascripthttps://github.com/getsentry/sentry-javascript
Codehttps://github.com/getsentry/sentry-javascript
Issues330 (330)https://github.com/getsentry/sentry-javascript/issues
Pull requests56 (56)https://github.com/getsentry/sentry-javascript/pulls
Discussionshttps://github.com/getsentry/sentry-javascript/discussions
Actionshttps://github.com/getsentry/sentry-javascript/actions
Security and quality7 (7)https://github.com/getsentry/sentry-javascript/security
Insightshttps://github.com/getsentry/sentry-javascript/insights
Sign up for GitHub https://github.com/signup?return_to=%2Fgetsentry%2Fsentry-javascript%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fgetsentry%2Fsentry-javascript%2Fissues%2Fnew%2Fchoose
chargomehttps://github.com/chargome
v9https://github.com/getsentry/sentry-javascript/tree/v9
cg-v9backport-flushifserverlesshttps://github.com/getsentry/sentry-javascript/tree/cg-v9backport-flushifserverless
Conversation 0 https://github.com/getsentry/sentry-javascript/pull/17239
Commits 1 https://github.com/getsentry/sentry-javascript/pull/17239/commits
Checks 0 https://github.com/getsentry/sentry-javascript/pull/17239/checks
Files changed https://github.com/getsentry/sentry-javascript/pull/17239/files
Please reload this pagehttps://github.com/getsentry/sentry-javascript/pull/17239/files
feat(v9/core): Add shared flushIfServerless function (#17177) https://github.com/getsentry/sentry-javascript/pull/17239/files#top
Show all changes 1 commit https://github.com/getsentry/sentry-javascript/pull/17239/files
9582aa4 feat(core): Add shared `flushIfServerless` function (#17177) s1gr1d Jul 30, 2025 https://github.com/getsentry/sentry-javascript/pull/17239/commits/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca
Clear filters https://github.com/getsentry/sentry-javascript/pull/17239/files
Please reload this pagehttps://github.com/getsentry/sentry-javascript/pull/17239/files
Please reload this pagehttps://github.com/getsentry/sentry-javascript/pull/17239/files
customNitroErrorHandler.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-adaa3d912f6e1134e25fe2e4de8cd8b4c7c4044bad07698e0ed840e9a791203e
middleware.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-e94a9f9c56d1c44471cedff02057558410865a4dbd7982df900ac58297be649a
index.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-9a4ceebe7c6f86856371906c3f061d3b56b7457022b05179884a113e7ced67e8
flushIfServerless.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-86666549d61dcab29e219144f7fb13167c527f06c19fd071afaa2f0013f46876
flushIfServerless.test.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-ef20137c83f0211f5e315361a8d51281125de22ca2f48aeb5210891ad3014291
withServerActionInstrumentation.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-482f0b47623b0529c4f4449e29e3f97c9c01d88b03f438e830d98bf5e8cb6b9e
wrapMiddlewareWithSentry.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-338aa218d53a58e523510d6e16918dee2f03aab75e7e0580b9fdc0f82db841b9
wrapServerComponentWithSentry.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-6a177c0f974e405d7e55f4d0155181376d92b37749269c0904cdc6e94b17ef84
captureErrorHook.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-07c983e23edc9d8bdafeb919b2ce2a3d4358baca908bade6bf794a0b4f38d90f
sentry.server.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-97c9dbdefa02cce633917c634379f727f66025791b7cf2abe159728ea862d1dd
utils.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-52a0959aca0fce75ce2335b2a71736ad131d2b9dc95f8a7c8619ad39badc7af7
sdk.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-3985820656eea992789aec90aa227afe115afe2d069fb26d129207ac3b15c786
utils.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-44f1f265bed7a8b8906a30d5e9b83c227a93c5f2e59b4e17e1947f87a011da50
withServerActionInstrumentation.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-f6d3e163ad2871f8f01c2066386982bc4b3bf13cc1b7fd159b6c924c2fad02c5
withServerActionInstrumentation.test.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-3edb198bffd10c5a8d963b39dce9d3de761cb98d91190f99a223b2a5fb5953db
handle.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-031f83f4ddbfb2aef7304917b383d17c8e29c9cba9f8415e03bf3e84d5e7955a
handleError.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-95cd95d30e47248f89635cac6628dfd930c2d87a8aa7c6ba82e9622941c6d411
load.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-1c4fde65de48b5bf8eb53f40fd37bc9451b99fbadfa26ba992ccdba8f158e45b
serverRoute.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-966f3cf0393f23c505b866f781320f6af204400b8d98b3f8631ff1650c097435
utils.ts https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-27ad07b4e9d9f9bfbd7f8c7d317ed59b5db0b1e78b6407e980432f06cc1a4bce
dev-packages/e2e-tests/test-applications/nuxt-3/server/plugins/customNitroErrorHandler.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-adaa3d912f6e1134e25fe2e4de8cd8b4c7c4044bad07698e0ed840e9a791203e
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/dev-packages/e2e-tests/test-applications/nuxt-3/server/plugins/customNitroErrorHandler.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-adaa3d912f6e1134e25fe2e4de8cd8b4c7c4044bad07698e0ed840e9a791203e
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-adaa3d912f6e1134e25fe2e4de8cd8b4c7c4044bad07698e0ed840e9a791203e
packages/astro/src/server/middleware.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-e94a9f9c56d1c44471cedff02057558410865a4dbd7982df900ac58297be649a
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/astro/src/server/middleware.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-e94a9f9c56d1c44471cedff02057558410865a4dbd7982df900ac58297be649a
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-e94a9f9c56d1c44471cedff02057558410865a4dbd7982df900ac58297be649a
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-e94a9f9c56d1c44471cedff02057558410865a4dbd7982df900ac58297be649a
packages/core/src/index.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-9a4ceebe7c6f86856371906c3f061d3b56b7457022b05179884a113e7ced67e8
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/core/src/index.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-9a4ceebe7c6f86856371906c3f061d3b56b7457022b05179884a113e7ced67e8
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-9a4ceebe7c6f86856371906c3f061d3b56b7457022b05179884a113e7ced67e8
packages/core/src/utils/flushIfServerless.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-86666549d61dcab29e219144f7fb13167c527f06c19fd071afaa2f0013f46876
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/core/src/utils/flushIfServerless.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
packages/core/test/lib/utils/flushIfServerless.test.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-ef20137c83f0211f5e315361a8d51281125de22ca2f48aeb5210891ad3014291
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/core/test/lib/utils/flushIfServerless.test.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
packages/nextjs/src/common/withServerActionInstrumentation.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-482f0b47623b0529c4f4449e29e3f97c9c01d88b03f438e830d98bf5e8cb6b9e
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/nextjs/src/common/withServerActionInstrumentation.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-482f0b47623b0529c4f4449e29e3f97c9c01d88b03f438e830d98bf5e8cb6b9e
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-482f0b47623b0529c4f4449e29e3f97c9c01d88b03f438e830d98bf5e8cb6b9e
packages/nextjs/src/common/wrapMiddlewareWithSentry.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-338aa218d53a58e523510d6e16918dee2f03aab75e7e0580b9fdc0f82db841b9
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/nextjs/src/common/wrapMiddlewareWithSentry.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-338aa218d53a58e523510d6e16918dee2f03aab75e7e0580b9fdc0f82db841b9
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-338aa218d53a58e523510d6e16918dee2f03aab75e7e0580b9fdc0f82db841b9
packages/nextjs/src/common/wrapServerComponentWithSentry.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-6a177c0f974e405d7e55f4d0155181376d92b37749269c0904cdc6e94b17ef84
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/nextjs/src/common/wrapServerComponentWithSentry.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-6a177c0f974e405d7e55f4d0155181376d92b37749269c0904cdc6e94b17ef84
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-6a177c0f974e405d7e55f4d0155181376d92b37749269c0904cdc6e94b17ef84
packages/nuxt/src/runtime/hooks/captureErrorHook.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-07c983e23edc9d8bdafeb919b2ce2a3d4358baca908bade6bf794a0b4f38d90f
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/nuxt/src/runtime/hooks/captureErrorHook.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-07c983e23edc9d8bdafeb919b2ce2a3d4358baca908bade6bf794a0b4f38d90f
packages/nuxt/src/runtime/plugins/sentry.server.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-97c9dbdefa02cce633917c634379f727f66025791b7cf2abe159728ea862d1dd
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/nuxt/src/runtime/plugins/sentry.server.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-97c9dbdefa02cce633917c634379f727f66025791b7cf2abe159728ea862d1dd
packages/nuxt/src/runtime/utils.tshttps://github.com/getsentry/sentry-javascript/pull/17239/files#diff-52a0959aca0fce75ce2335b2a71736ad131d2b9dc95f8a7c8619ad39badc7af7
View file https://github.com/getsentry/sentry-javascript/blob/9582aa4bcbe868e08e03a9c80ccaa040ba3dc0ca/packages/nuxt/src/runtime/utils.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/getsentry/sentry-javascript/pull/17239/{{ revealButtonHref }}
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-52a0959aca0fce75ce2335b2a71736ad131d2b9dc95f8a7c8619ad39badc7af7
https://github.com/getsentry/sentry-javascript/pull/17239/files#diff-52a0959aca0fce75ce2335b2a71736ad131d2b9dc95f8a7c8619ad39badc7af7
Please reload this pagehttps://github.com/getsentry/sentry-javascript/pull/17239/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Response headers:
Servergithub.com
Content-Typetext/html; charset=utf-8
Cache-Controlno-cache

Viewport: width=device-width


URLs of crawlers that visited me.