Skip to content

fix(appStart): Add frame data in app start span #4865

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 14 commits into from
Jun 18, 2025
Merged

Conversation

antonis
Copy link
Collaborator

@antonis antonis commented May 27, 2025

📢 Type of change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring

📜 Description

Add frame data in app start span.

Note: The frames.delay (as it appears in the #4723 example) is not added with this PR since it would require native changes. To keep the implementation simple a followup PR will tackle #4869

💡 Motivation and Context

Fixes #4931 part of #4723

💚 How did you test it?

CI, Manual
Examples: cold, warm

📝 Checklist

  • I added tests to verify changes
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled
  • I updated the docs if needed.
  • I updated the wizard if needed.
  • All tests passing
  • No breaking changes

🔮 Next steps

@antonis antonis changed the title feat(appStart): Add frame data in app start span fix(appStart): Add frame data in app start span May 27, 2025
Copy link
Contributor

github-actions bot commented May 27, 2025

Android (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 426.10 ms 428.12 ms 2.02 ms
Size 17.75 MiB 20.15 MiB 2.40 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
ec2a485 450.84 ms 447.49 ms -3.35 ms
c352c30 331.98 ms 321.78 ms -10.20 ms
e12044e 453.78 ms 437.58 ms -16.20 ms
1f1c420 403.32 ms 411.98 ms 8.66 ms
f2c6fa5 445.15 ms 449.13 ms 3.98 ms
b4d6bde 425.51 ms 417.37 ms -8.14 ms
7d3c3cb 444.85 ms 456.65 ms 11.81 ms
df5da5d 425.55 ms 432.96 ms 7.41 ms
52d9c3f 481.48 ms 468.53 ms -12.95 ms
0e42017 402.23 ms 415.04 ms 12.81 ms

App size

Revision Plain With Sentry Diff
ec2a485 17.75 MiB 20.15 MiB 2.40 MiB
c352c30 17.75 MiB 20.15 MiB 2.40 MiB
e12044e 17.75 MiB 20.15 MiB 2.40 MiB
1f1c420 17.75 MiB 20.15 MiB 2.40 MiB
f2c6fa5 17.75 MiB 20.15 MiB 2.40 MiB
b4d6bde 17.75 MiB 20.15 MiB 2.40 MiB
7d3c3cb 17.75 MiB 20.15 MiB 2.40 MiB
df5da5d 17.75 MiB 20.15 MiB 2.40 MiB
52d9c3f 17.75 MiB 20.15 MiB 2.40 MiB
0e42017 17.75 MiB 20.15 MiB 2.40 MiB

Previous results on branch: antonis/appstart-frames

Startup times

Revision Plain With Sentry Diff
316bdde 410.04 ms 432.95 ms 22.91 ms
8a3bfd9 419.98 ms 416.00 ms -3.98 ms
8e02cac 427.29 ms 414.76 ms -12.54 ms
b2affff 475.47 ms 473.64 ms -1.83 ms
ee8c5ed 404.21 ms 394.15 ms -10.06 ms
c092483 432.67 ms 421.38 ms -11.29 ms

App size

Revision Plain With Sentry Diff
316bdde 17.75 MiB 20.15 MiB 2.40 MiB
8a3bfd9 17.75 MiB 20.15 MiB 2.40 MiB
8e02cac 17.75 MiB 20.15 MiB 2.40 MiB
b2affff 17.75 MiB 20.15 MiB 2.40 MiB
ee8c5ed 17.75 MiB 20.15 MiB 2.40 MiB
c092483 17.75 MiB 20.15 MiB 2.40 MiB

@antonis antonis marked this pull request as ready for review May 27, 2025 18:39
Copy link
Contributor

github-actions bot commented May 27, 2025

Android (new) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 392.12 ms 387.69 ms -4.43 ms
Size 7.15 MiB 8.42 MiB 1.26 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
e12044e+dirty 404.20 ms 398.15 ms -6.06 ms
0e42017+dirty 387.33 ms 399.30 ms 11.97 ms
f2c6fa5+dirty 435.84 ms 433.84 ms -2.00 ms
ec2a485+dirty 397.67 ms 390.91 ms -6.76 ms
b4d6bde+dirty 390.51 ms 385.60 ms -4.91 ms
1f1c420+dirty 383.31 ms 386.98 ms 3.67 ms
7d3c3cb+dirty 395.20 ms 413.24 ms 18.04 ms
940bd65+dirty 408.45 ms 419.75 ms 11.30 ms
6e8a851+dirty 403.44 ms 430.87 ms 27.43 ms
df5da5d+dirty 415.54 ms 456.96 ms 41.42 ms

App size

Revision Plain With Sentry Diff
e12044e+dirty 7.15 MiB 8.42 MiB 1.26 MiB
0e42017+dirty 7.15 MiB 8.42 MiB 1.26 MiB
f2c6fa5+dirty 7.15 MiB 8.42 MiB 1.26 MiB
ec2a485+dirty 7.15 MiB 8.42 MiB 1.26 MiB
b4d6bde+dirty 7.15 MiB 8.42 MiB 1.26 MiB
1f1c420+dirty 7.15 MiB 8.42 MiB 1.26 MiB
7d3c3cb+dirty 7.15 MiB 8.42 MiB 1.26 MiB
940bd65+dirty 7.15 MiB 8.42 MiB 1.26 MiB
6e8a851+dirty 7.15 MiB 8.42 MiB 1.26 MiB
df5da5d+dirty 7.15 MiB 8.42 MiB 1.26 MiB

Previous results on branch: antonis/appstart-frames

Startup times

Revision Plain With Sentry Diff
8a3bfd9+dirty 415.89 ms 430.87 ms 14.98 ms
8e02cac+dirty 377.75 ms 395.52 ms 17.77 ms
c092483+dirty 401.00 ms 394.06 ms -6.94 ms
ee8c5ed+dirty 392.27 ms 418.56 ms 26.29 ms
b2affff+dirty 474.94 ms 458.52 ms -16.42 ms
316bdde+dirty 406.72 ms 406.41 ms -0.31 ms

App size

Revision Plain With Sentry Diff
8a3bfd9+dirty 7.15 MiB 8.42 MiB 1.26 MiB
8e02cac+dirty 7.15 MiB 8.42 MiB 1.26 MiB
c092483+dirty 7.15 MiB 8.42 MiB 1.26 MiB
ee8c5ed+dirty 7.15 MiB 8.42 MiB 1.26 MiB
b2affff+dirty 7.15 MiB 8.42 MiB 1.26 MiB
316bdde+dirty 7.15 MiB 8.42 MiB 1.26 MiB

Copy link
Contributor

github-actions bot commented May 27, 2025

iOS (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1220.20 ms 1219.18 ms -1.02 ms
Size 2.63 MiB 3.79 MiB 1.15 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
6e8a851+dirty 1227.96 ms 1235.61 ms 7.65 ms
e12044e+dirty 1233.45 ms 1233.66 ms 0.21 ms
0e42017+dirty 1225.89 ms 1231.63 ms 5.74 ms
b4d6bde+dirty 1223.22 ms 1243.56 ms 20.34 ms
df5da5d+dirty 1235.98 ms 1243.41 ms 7.43 ms
940bd65+dirty 1216.88 ms 1225.23 ms 8.35 ms
7d3c3cb+dirty 1226.39 ms 1227.10 ms 0.71 ms
c352c30+dirty 1216.60 ms 1231.37 ms 14.77 ms
8bd8033+dirty 1213.33 ms 1220.88 ms 7.55 ms
1f1c420+dirty 1216.77 ms 1214.48 ms -2.29 ms

App size

Revision Plain With Sentry Diff
6e8a851+dirty 2.63 MiB 3.78 MiB 1.15 MiB
e12044e+dirty 2.63 MiB 3.78 MiB 1.15 MiB
0e42017+dirty 2.63 MiB 3.78 MiB 1.15 MiB
b4d6bde+dirty 2.63 MiB 3.77 MiB 1.14 MiB
df5da5d+dirty 2.63 MiB 3.78 MiB 1.15 MiB
940bd65+dirty 2.63 MiB 3.78 MiB 1.15 MiB
7d3c3cb+dirty 2.63 MiB 3.78 MiB 1.15 MiB
c352c30+dirty 2.63 MiB 3.78 MiB 1.15 MiB
8bd8033+dirty 2.63 MiB 3.78 MiB 1.15 MiB
1f1c420+dirty 2.63 MiB 3.77 MiB 1.14 MiB

Previous results on branch: antonis/appstart-frames

Startup times

Revision Plain With Sentry Diff
b2affff+dirty 1222.06 ms 1221.27 ms -0.80 ms
ee8c5ed+dirty 1227.47 ms 1228.49 ms 1.02 ms
c092483+dirty 1224.31 ms 1221.23 ms -3.08 ms
316bdde+dirty 1223.49 ms 1236.15 ms 12.66 ms
8e02cac+dirty 1233.49 ms 1225.38 ms -8.11 ms
8a3bfd9+dirty 1225.81 ms 1229.79 ms 3.98 ms

App size

Revision Plain With Sentry Diff
b2affff+dirty 2.63 MiB 3.78 MiB 1.15 MiB
ee8c5ed+dirty 2.63 MiB 3.79 MiB 1.15 MiB
c092483+dirty 2.63 MiB 3.79 MiB 1.15 MiB
316bdde+dirty 2.63 MiB 3.78 MiB 1.15 MiB
8e02cac+dirty 2.63 MiB 3.79 MiB 1.15 MiB
8a3bfd9+dirty 2.63 MiB 3.78 MiB 1.14 MiB

Copy link
Contributor

github-actions bot commented May 27, 2025

iOS (new) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1230.23 ms 1232.60 ms 2.37 ms
Size 3.19 MiB 4.35 MiB 1.17 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
e12044e+dirty 1234.49 ms 1228.85 ms -5.64 ms
940bd65+dirty 1224.39 ms 1215.57 ms -8.82 ms
c352c30+dirty 1229.65 ms 1241.33 ms 11.67 ms
ec2a485+dirty 1209.65 ms 1229.18 ms 19.53 ms
7d3c3cb+dirty 1214.56 ms 1234.53 ms 19.97 ms
f2c6fa5+dirty 1223.47 ms 1227.37 ms 3.90 ms
6e8a851+dirty 1222.57 ms 1223.67 ms 1.10 ms
b4d6bde+dirty 1218.73 ms 1223.26 ms 4.53 ms
0e42017+dirty 1235.77 ms 1247.43 ms 11.66 ms
1f1c420+dirty 1238.06 ms 1234.04 ms -4.02 ms

App size

Revision Plain With Sentry Diff
e12044e+dirty 3.19 MiB 4.35 MiB 1.17 MiB
940bd65+dirty 3.19 MiB 4.35 MiB 1.16 MiB
c352c30+dirty 3.19 MiB 4.35 MiB 1.17 MiB
ec2a485+dirty 3.19 MiB 4.35 MiB 1.17 MiB
7d3c3cb+dirty 3.19 MiB 4.35 MiB 1.16 MiB
f2c6fa5+dirty 3.19 MiB 4.35 MiB 1.17 MiB
6e8a851+dirty 3.19 MiB 4.35 MiB 1.17 MiB
b4d6bde+dirty 3.19 MiB 4.34 MiB 1.16 MiB
0e42017+dirty 3.19 MiB 4.35 MiB 1.16 MiB
1f1c420+dirty 3.19 MiB 4.34 MiB 1.16 MiB

Previous results on branch: antonis/appstart-frames

Startup times

Revision Plain With Sentry Diff
b2affff+dirty 1229.60 ms 1227.96 ms -1.64 ms
ee8c5ed+dirty 1223.69 ms 1235.62 ms 11.93 ms
c092483+dirty 1235.59 ms 1251.14 ms 15.55 ms
316bdde+dirty 1221.72 ms 1218.04 ms -3.68 ms
8e02cac+dirty 1225.16 ms 1225.36 ms 0.19 ms
8a3bfd9+dirty 1220.87 ms 1237.55 ms 16.68 ms

App size

Revision Plain With Sentry Diff
b2affff+dirty 3.19 MiB 4.35 MiB 1.17 MiB
ee8c5ed+dirty 3.19 MiB 4.35 MiB 1.17 MiB
c092483+dirty 3.19 MiB 4.35 MiB 1.17 MiB
316bdde+dirty 3.19 MiB 4.35 MiB 1.17 MiB
8e02cac+dirty 3.19 MiB 4.35 MiB 1.17 MiB
8a3bfd9+dirty 3.19 MiB 4.34 MiB 1.16 MiB

@lucas-zimerman
Copy link
Collaborator

I would add a sub issue to keep track of the missing native data.

@antonis
Copy link
Collaborator Author

antonis commented May 28, 2025

I would add a sub issue to keep track of the missing native data.

Good point @lucas-zimerman 👍 Created #4869

Copy link
Collaborator

@lucas-zimerman lucas-zimerman left a comment

Choose a reason for hiding this comment

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

I double-checked the PR and I found no issues with it, LGTM!

CHANGELOG.md Outdated
@@ -52,6 +52,7 @@
- Use engine-specific promise rejection tracking ([#4826](https://github.com/getsentry/sentry-react-native/pull/4826))
- Fixes Feedback Widget accessibility issue on iOS ([#4739](https://github.com/getsentry/sentry-react-native/pull/4739))
- Measuring TTID or TTFD could cause a crash when `parentSpanId` was removed ([#4881](https://github.com/getsentry/sentry-react-native/pull/4881))
- Report slow and frozen frames as app start span data ([#4865](https://github.com/getsentry/sentry-react-native/pull/4865))
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

fixed with 4dc6765

@antonis antonis merged commit 69721ae into main Jun 18, 2025
124 of 127 checks passed
@antonis antonis deleted the antonis/appstart-frames branch June 18, 2025 11:03
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.

Add slow and frozen frame in app start span data
2 participants