René's URL Explorer Experiment


Title: RequestData integration prework, work, and postwork · Issue #5756 · getsentry/sentry-javascript · GitHub

Open Graph Title: RequestData integration prework, work, and postwork · Issue #5756 · getsentry/sentry-javascript

X Title: RequestData integration prework, work, and postwork · Issue #5756 · getsentry/sentry-javascript

Description: There have gotten to be enough moving parts and dependencies involved in the RequestData integration work that I figured it's worth writing them all down. Background The underlying request-data-adding functions got moved from @sentry/nod...

Open Graph Description: There have gotten to be enough moving parts and dependencies involved in the RequestData integration work that I figured it's worth writing them all down. Background The underlying request-data-add...

X Description: There have gotten to be enough moving parts and dependencies involved in the RequestData integration work that I figured it's worth writing them all down. Background The underlying request-data...

Opengraph URL: https://github.com/getsentry/sentry-javascript/issues/5756

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.112.4


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"RequestData integration prework, work, and postwork","articleBody":"There have gotten to be enough moving parts and dependencies involved in the `RequestData` integration work that I figured it's worth writing them all down.\r\n\r\n### Background\r\n\r\n- The underlying request-data-adding functions got moved from `@sentry/node` to `@sentry/utils` in order to be able to use them in the `_error` helper in the nextjs SDK, which runs in both browser and node and therefore must be platform agnostic. (The function is only actually called in node, but has to be imported from a neutral source.) As a result of that change, node-specific dependencies needed for those functions were forced to be provided via dependency injection, by wrapper functions in the node SDK.\r\n- The new data-fetcher wrappers in the nextjs SDK needed a new way to use the functions. (We currently use them in scope-specific event processors, but the events those wrappers create pass through a number of different scopes, so that won't work for them.) To solve this, and to bring continuity to our use of the functions, we decided to create an integration.\r\n- There was a recent DACI wherein we decided that we eventually want to add the same data to events tracking fetch requests in the browser.\r\n\r\n### Problems/Constraints\r\n\r\n- The functions themselves are part of the Great Transaction Mess (see https://github.com/getsentry/sentry-javascript/issues/5718 and https://github.com/getsentry/sentry-javascript/issues/5660).\r\n- The dependency injection is kind of gross and hard to follow.\r\n- It's unclear how much overlap there'll be between the node and browser versions of the integration, and the browser version isn't yet roadmapped (and therefore we don't know how soon it will happen).\r\n- Because of the above two points, we decided to undo the move from node to utils, because once the integration is in use, the _error helper doesn't need to use the functions directly. Until it is, though, the helper still needs the function to live in the utils package.\r\n\r\n### Order of Operations\r\n\r\nImmediate term:\r\n\r\n- [x] Create polymorphic request type so request can be stored on transaction (https://github.com/getsentry/sentry-javascript/pull/5744)\r\n- [x] Move the functions back to the node package, but leave them also in utils for now (https://github.com/getsentry/sentry-javascript/pull/5759)\r\n- [x] Use integration for nextjs transactions (https://github.com/getsentry/sentry-javascript/pull/5703)\r\n- [x] Use integration for nextjs errors (https://github.com/getsentry/sentry-javascript/pull/5729)\r\n- [x] Make integration default for node-based SDKs (https://github.com/getsentry/sentry-javascript/pull/5980)\r\n- [x] Clean up integration (https://github.com/getsentry/sentry-javascript/pull/5979)\r\n- [x] Use integration for express transactions and errors (https://github.com/getsentry/sentry-javascript/pull/5990)\r\n- [x] Use integration for GCP wrapper (https://github.com/getsentry/sentry-javascript/pull/5991)\r\n- [x] Use integration for remix (https://github.com/getsentry/sentry-javascript/pull/6007)\r\n- [x] Document integration and options to control what data is attached (https://github.com/getsentry/sentry-docs/pull/5674)\r\n- [ ] Mark future removals as deprecated and label all related TODOs (see v8 section below)\r\n\r\nLonger term:\r\n\r\n- [ ] Clean up transaction mess\r\n- [ ] Move extra logic from integration to revamped request-data-adding functions\r\n- [ ] Once browser version of integration is needed, figure out if we want to factor out common functionality or just make a separate integration\r\n\r\nv8 Removals/Deprecations/Breaking Changes:\r\n\r\n_(WIP - may not be an exhaustive list)_\r\n\r\n- [ ] Remove `requestDataDeprecated.ts` (`parseRequest` and friends)\r\n- [ ] Remove tests testing `parseRequest`/`addRequestDataToEvent` compatibility\r\n- [ ] Remove utils copy of request data functions\r\n- [ ]  Make express request handler no longer take request data options (users can use integration options)\r\n- [ ] Make CGP wrapper no longer take request data options (users can use integration options)\r\n- [ ] Remove helper functions converting between `parseRequest`, `addRequestDataToEvent`, and `RequestData` integration options\r\n","author":{"url":"https://github.com/lobsterkatie","@type":"Person","name":"lobsterkatie"},"datePublished":"2022-09-16T01:59:25Z","url":"https://github.com/getsentry/sentry-javascript/issues/5756"}

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/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:18a79327-535c-e43b-e882-84babd8a507c
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idC764:250A6C:3F244:52399:6B042FAE
html-safe-noncec88e39874f23f7c842814421c9948008e8e65cd5573c6efc58f6a6aa69ffd384
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDNzY0OjI1MEE2QzozRjI0NDo1MjM5OTo2QjA0MkZBRSIsInZpc2l0b3JfaWQiOiI2NzcyNTIzOTQ5OTA2NzM1MDIyIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmacce6a516c30eebef17611e6fc6027fb3a8e9f59ff9c7e01f8bb3bb6375a162dcd
hovercard-subject-tagissue:1375288382
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/getsentry/sentry-javascript/5756/issue_layout
twitter:imagehttps://opengraph.githubassets.com/10a59c9919be6d1c4a320ddf627c20c99b82b47290de11156bdf0ced5e446a94/getsentry/sentry-javascript/issues/5756
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/10a59c9919be6d1c4a320ddf627c20c99b82b47290de11156bdf0ced5e446a94/getsentry/sentry-javascript/issues/5756
og:image:altThere have gotten to be enough moving parts and dependencies involved in the RequestData integration work that I figured it's worth writing them all down. Background The underlying request-data-add...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamelobsterkatie
hostnamegithub.com
expected-hostnamegithub.com
Noneb7a1d2b9101496921b08579fbee988d014345aef2f5bd660d1f8c7332d81560e
turbo-cache-controlno-preview
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
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasec3dd496c3da6ea6b77e69c09279d2b81604654f1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/getsentry/sentry-javascript/issues/5756#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgetsentry%2Fsentry-javascript%2Fissues%2F5756
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%2Fissues%2F5756
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=getsentry%2Fsentry-javascript
Reloadhttps://github.com/getsentry/sentry-javascript/issues/5756
Reloadhttps://github.com/getsentry/sentry-javascript/issues/5756
Reloadhttps://github.com/getsentry/sentry-javascript/issues/5756
getsentryhttps://github.com/getsentry
sentry-javascripthttps://github.com/getsentry/sentry-javascript
Codehttps://github.com/getsentry/sentry-javascript
Issues341 (341)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
https://github.com/getsentry/sentry-javascript
New issuehttps://github.com/login?return_to=https://github.com/getsentry/sentry-javascript/issues/5756
New issuehttps://github.com/login?return_to=https://github.com/getsentry/sentry-javascript/issues/5756
RequestData integration prework, work, and postworkhttps://github.com/getsentry/sentry-javascript/issues/5756#top
https://github.com/lobsterkatie
https://github.com/lobsterkatie
lobsterkatiehttps://github.com/lobsterkatie
on Sep 16, 2022https://github.com/getsentry/sentry-javascript/issues/5756#issue-1375288382
Clean up code relating to scope/event transaction value  #5718https://github.com/getsentry/sentry-javascript/issues/5718
Problematic API: Scope.setTransactionName() #5660https://github.com/getsentry/sentry-javascript/issues/5660
feat(types): Add PolymorphicRequest type #5744https://github.com/getsentry/sentry-javascript/pull/5744
ref(node): Move request data functions back to@sentry/node #5759https://github.com/getsentry/sentry-javascript/pull/5759
ref(nextjs): Use integration to add request data to transaction events #5703https://github.com/getsentry/sentry-javascript/pull/5703
ref(nextjs): UseRequestData integration for errors #5729https://github.com/getsentry/sentry-javascript/pull/5729
ref(node): Make RequestData integration default #5980https://github.com/getsentry/sentry-javascript/pull/5980
ref(node): Small RequestData integration tweaks #5979https://github.com/getsentry/sentry-javascript/pull/5979
ref(node): Use RequestData integration in express handlers #5990https://github.com/getsentry/sentry-javascript/pull/5990
ref(serverless): Use RequestData integration in GCP wrapper #5991https://github.com/getsentry/sentry-javascript/pull/5991
feat(remix): Enable RequestData integration for server-side requests #6007https://github.com/getsentry/sentry-javascript/pull/6007
add RequestData integration sentry-docs#5674https://github.com/getsentry/sentry-docs/pull/5674
lobsterkatiehttps://github.com/lobsterkatie
on Sep 17, 2022https://github.com/getsentry/sentry-javascript/issues/5756#event-7407085934
ref(node): Move request data functions back to`@sentry/node` (#5759)https://github.com/getsentry/sentry-javascript/commit/9862a32899a41a3af9a5cd87c0d4a09a1d689e25
#5759https://github.com/getsentry/sentry-javascript/pull/5759
9862a32https://github.com/getsentry/sentry-javascript/commit/9862a32899a41a3af9a5cd87c0d4a09a1d689e25
https://github.com/vladanpaunovic
vladanpaunovichttps://github.com/vladanpaunovic
on Sep 30, 2022https://github.com/getsentry/sentry-javascript/issues/5756#issuecomment-1263585763
@lobsterkatiehttps://github.com/lobsterkatie
https://github.com/lobsterkatie
lobsterkatiehttps://github.com/lobsterkatie
on Oct 5, 2022https://github.com/getsentry/sentry-javascript/issues/5756#issuecomment-1269117261
@lobsterkatiehttps://github.com/lobsterkatie
#4723https://github.com/getsentry/sentry-javascript/issues/4723
vladanpaunovichttps://github.com/vladanpaunovic
lobsterkatiehttps://github.com/lobsterkatie
on Oct 12, 2022https://github.com/getsentry/sentry-javascript/issues/5756#event-7572320911
lobsterkatiehttps://github.com/lobsterkatie
Status: In Progresshttps://github.com/getsentry/sentry-javascript/issues?q=state%3Aopen%20label%3A%22Status%3A%20In%20Progress%22
Status: Backloghttps://github.com/getsentry/sentry-javascript/issues?q=state%3Aopen%20label%3A%22Status%3A%20Backlog%22
on Oct 19, 2022https://github.com/getsentry/sentry-javascript/issues/5756#event-7618950772
lobsterkatiehttps://github.com/lobsterkatie
on Oct 20, 2022https://github.com/getsentry/sentry-javascript/issues/5756#event-7630990211
ref(node): Use `RequestData` integration in express handlers (#5990)https://github.com/getsentry/sentry-javascript/commit/1f99c3b201c229f045595c63cb40d17390c639f0
#5990https://github.com/getsentry/sentry-javascript/pull/5990
1f99c3bhttps://github.com/getsentry/sentry-javascript/commit/1f99c3b201c229f045595c63cb40d17390c639f0
ref(serverless): Use `RequestData` integration in GCP wrapper (#5991)https://github.com/getsentry/sentry-javascript/commit/0576852aee4ed2c0a8b76729f27aedeebbabea97
#5991https://github.com/getsentry/sentry-javascript/pull/5991
0576852https://github.com/getsentry/sentry-javascript/commit/0576852aee4ed2c0a8b76729f27aedeebbabea97
https://github.com/HazAT
HazAThttps://github.com/HazAT
on Feb 16, 2023https://github.com/getsentry/sentry-javascript/issues/5756#issuecomment-1432712386
HazAThttps://github.com/HazAT
completedhttps://github.com/getsentry/sentry-javascript/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
on Feb 16, 2023https://github.com/getsentry/sentry-javascript/issues/5756#event-8534362125
Sign up for freehttps://github.com/signup?return_to=https://github.com/getsentry/sentry-javascript/issues/5756
Sign in to commenthttps://github.com/login?return_to=https://github.com/getsentry/sentry-javascript/issues/5756
lobsterkatiehttps://github.com/lobsterkatie
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-Controlmax-age=0, private, must-revalidate

Viewport: width=device-width


URLs of crawlers that visited me.