Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

ref(browser): Create standalone INP spans via startInactiveSpan #11788

Merged
merged 2 commits into from Apr 25, 2024

Conversation

Lms24
Copy link
Member

@Lms24 Lms24 commented Apr 25, 2024

builds on top of #11696 #11699

This PR refactors how we create INP spans. Previously we'd directly initialize a SentrySpan instance with the necessary properties and manually sample the span. Ironically, we heavily discourage directly initializing a Span class.

With this refactor PR, we leverage the standalone: true flag introduced in #11696. This way, we can also use the built-in sampling functionality and ensure that we only have one logic for creating standalone span envelopes. Also bundle size should decrease slightly 馃

Adjusted the integration tests to more thoroughly test the INP span envelopes

@Lms24 Lms24 changed the base branch from develop to lms/feat-core-span-envelope-trace-header April 25, 2024 13:37
@Lms24 Lms24 requested review from AbhiPrasad and s1gr1d April 25, 2024 13:43
Copy link
Contributor

github-actions bot commented Apr 25, 2024

size-limit report 馃摝

Path Size
@sentry/browser 21.65 KB (0%)
@sentry/browser (incl. Tracing) 32.68 KB (-0.09% 馃斀)
@sentry/browser (incl. Tracing, Replay) 68.02 KB (-0.1% 馃斀)
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 61.42 KB (-0.09% 馃斀)
@sentry/browser (incl. Tracing, Replay with Canvas) 72.06 KB (-0.11% 馃斀)
@sentry/browser (incl. Tracing, Replay, Feedback) 84.27 KB (-0.09% 馃斀)
@sentry/browser (incl. Feedback) 37.79 KB (0%)
@sentry/browser (incl. sendFeedback) 26.43 KB (0%)
@sentry/browser (incl. FeedbackAsync) 30.93 KB (0%)
@sentry/react 24.33 KB (0%)
@sentry/react (incl. Tracing) 35.64 KB (-0.06% 馃斀)
@sentry/vue 25.47 KB (+0.1% 馃敽)
@sentry/vue (incl. Tracing) 34.47 KB (-0.04% 馃斀)
@sentry/svelte 21.77 KB (0%)
CDN Bundle 23.95 KB (0%)
CDN Bundle (incl. Tracing) 33.96 KB (-0.19% 馃斀)
CDN Bundle (incl. Tracing, Replay) 67.65 KB (-0.09% 馃斀)
CDN Bundle (incl. Tracing, Replay, Feedback) 83.53 KB (-0.07% 馃斀)
CDN Bundle - uncompressed 70.56 KB (0%)
CDN Bundle (incl. Tracing) - uncompressed 100.88 KB (-0.12% 馃斀)
CDN Bundle (incl. Tracing, Replay) - uncompressed 210.49 KB (-0.06% 馃斀)
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 256.88 KB (-0.05% 馃斀)
@sentry/nextjs (client) 34.86 KB (-0.06% 馃斀)
@sentry/sveltekit (client) 33.24 KB (-0.06% 馃斀)
@sentry/node 138.48 KB (0%)

@Lms24 Lms24 force-pushed the lms/feat-core-span-envelope-trace-header branch from 47a67db to 5095e82 Compare April 25, 2024 14:46
Base automatically changed from lms/feat-core-span-envelope-trace-header to develop April 25, 2024 15:19
@Lms24 Lms24 force-pushed the lms/ref-browser-inp-standalone-span branch from 28df9db to 3a547f7 Compare April 25, 2024 15:32
@Lms24 Lms24 enabled auto-merge (squash) April 25, 2024 15:47
@Lms24 Lms24 merged commit a0415aa into develop Apr 25, 2024
94 checks passed
@Lms24 Lms24 deleted the lms/ref-browser-inp-standalone-span branch April 25, 2024 16:18
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.

None yet

2 participants