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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Calculate frame delay, slow+frozen frames inside SentryFrameMetricsCollector #3100

Merged
merged 3 commits into from
Dec 15, 2023

Conversation

markushi
Copy link
Member

@markushi markushi commented Dec 14, 2023

Do it in one place, so we can later use it for both the AndroidProfiler as well as txns.

📜 Description

Mainly moved some logic from AndroidProfiler to SentryFrameMetricsAggregator.
Added some logic to calculate the frame delay, as well as exposing frame start/end times.

💡 Motivation and Context

Partly fixes #3099

💚 How did you test it?

Added unit tests.

📝 Checklist

  • I reviewed the submitted code.
  • I added tests to verify the changes.
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled.
  • I updated the docs if needed.
  • Review from the native team if needed.
  • No breaking change or entry added to the changelog.
  • No breaking change for hybrid SDKs or communicated to hybrid SDKs.

🔮 Next steps

…llector

So we can later use it later for span attribution
Copy link
Contributor

github-actions bot commented Dec 14, 2023

Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against 6b94562

Copy link
Contributor

github-actions bot commented Dec 14, 2023

Performance metrics 🚀

  Plain With Sentry Diff
Startup time 365.83 ms 439.90 ms 74.07 ms
Size 1.72 MiB 2.27 MiB 556.88 KiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
a3c77bc 375.80 ms 445.85 ms 70.06 ms
93a76ca 378.48 ms 451.78 ms 73.30 ms
b172d4e 412.60 ms 492.68 ms 80.08 ms
b172d4e 413.47 ms 479.02 ms 65.55 ms
4e260b3 378.73 ms 454.18 ms 75.45 ms
c7e2fbc 398.35 ms 468.52 ms 70.17 ms
0bd723b 412.52 ms 496.65 ms 84.13 ms
2fad834 390.07 ms 470.80 ms 80.73 ms
93a76ca 391.54 ms 475.65 ms 84.11 ms
93a76ca 397.30 ms 455.16 ms 57.87 ms

App size

Revision Plain With Sentry Diff
a3c77bc 1.72 MiB 2.29 MiB 577.53 KiB
93a76ca 1.72 MiB 2.29 MiB 576.75 KiB
b172d4e 1.72 MiB 2.29 MiB 578.09 KiB
b172d4e 1.72 MiB 2.29 MiB 578.09 KiB
4e260b3 1.72 MiB 2.27 MiB 554.95 KiB
c7e2fbc 1.72 MiB 2.29 MiB 576.40 KiB
0bd723b 1.72 MiB 2.29 MiB 578.09 KiB
2fad834 1.72 MiB 2.29 MiB 577.53 KiB
93a76ca 1.72 MiB 2.29 MiB 576.75 KiB
93a76ca 1.72 MiB 2.29 MiB 576.75 KiB

Previous results on branch: feat/slow-frozen-delayed-frame-calculations

Startup times

Revision Plain With Sentry Diff
4c5f4e3 425.22 ms 500.21 ms 74.98 ms
faad870 413.04 ms 488.98 ms 75.94 ms

App size

Revision Plain With Sentry Diff
4c5f4e3 1.72 MiB 2.27 MiB 556.88 KiB
faad870 1.72 MiB 2.27 MiB 557.05 KiB

Copy link
Member

@stefanosiano stefanosiano left a comment

Choose a reason for hiding this comment

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

just a change in the cpuDuration vs totalDuration
Everything else is good!

@markushi markushi merged commit 8d62770 into main Dec 15, 2023
18 checks passed
@markushi markushi deleted the feat/slow-frozen-delayed-frame-calculations branch December 15, 2023 08: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.

[Starfish] Add frame delay for transactions and spans
2 participants