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

enha: replay: use rawRGBA for replay native integration on ios #2573

Merged
merged 33 commits into from
Jan 14, 2025

Conversation

vaind
Copy link
Collaborator

@vaind vaind commented Jan 13, 2025

📜 Description

Dart PNG conversion is rather slow (about 350 ms for a single screenshot) and may be unnecessary. We can leave it up to the native code to handle images in bitmap.

💡 Motivation and Context

💚 How did you test it?

📝 Checklist

  • I reviewed submitted code
  • 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
  • All tests passing
  • No breaking changes

🔮 Next steps

Android is a bit more complicated to implement and would benefit from bumping to a higher Dart SDK version (3.5)

Copy link

codecov bot commented Jan 13, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.60%. Comparing base (d1488a1) to head (b9774d4).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2573      +/-   ##
==========================================
+ Coverage   87.29%   92.60%   +5.31%     
==========================================
  Files         268       91     -177     
  Lines        9342     3004    -6338     
==========================================
- Hits         8155     2782    -5373     
+ Misses       1187      222     -965     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

Android Performance metrics 🚀

  Plain With Sentry Diff
Startup time 501.63 ms 578.04 ms 76.41 ms
Size 6.46 MiB 7.48 MiB 1.02 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
3de8b9b 348.55 ms 445.84 ms 97.29 ms
6d50a9b 467.98 ms 526.48 ms 58.50 ms
3a16179 471.61 ms 513.45 ms 41.83 ms
ebfead1 298.44 ms 374.28 ms 75.84 ms
f056db1 426.04 ms 475.76 ms 49.72 ms
2a0edba 376.12 ms 454.00 ms 77.88 ms
256df44 447.58 ms 485.84 ms 38.25 ms
ef31c7f 311.39 ms 359.33 ms 47.94 ms
c978477 347.00 ms 409.94 ms 62.94 ms
3500574 288.69 ms 358.34 ms 69.65 ms

App size

Revision Plain With Sentry Diff
3de8b9b 6.27 MiB 7.20 MiB 957.75 KiB
6d50a9b 6.49 MiB 7.55 MiB 1.06 MiB
3a16179 6.52 MiB 7.61 MiB 1.08 MiB
ebfead1 6.06 MiB 7.03 MiB 989.24 KiB
f056db1 6.52 MiB 7.61 MiB 1.09 MiB
2a0edba 6.33 MiB 7.30 MiB 992.46 KiB
256df44 6.52 MiB 7.59 MiB 1.06 MiB
ef31c7f 6.06 MiB 7.09 MiB 1.03 MiB
c978477 6.33 MiB 7.29 MiB 987.32 KiB
3500574 6.16 MiB 7.14 MiB 1009.90 KiB

Previous results on branch: feat/replay-bitmap-transfer

Startup times

Revision Plain With Sentry Diff
7f1fbf4 455.48 ms 538.04 ms 82.56 ms
9d6fbb7 463.67 ms 470.42 ms 6.75 ms

App size

Revision Plain With Sentry Diff
7f1fbf4 6.46 MiB 7.48 MiB 1.02 MiB
9d6fbb7 6.46 MiB 7.48 MiB 1.02 MiB

Copy link
Contributor

github-actions bot commented Jan 13, 2025

iOS Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1250.98 ms 1275.10 ms 24.12 ms
Size 8.42 MiB 9.89 MiB 1.46 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
202b83f 1206.16 ms 1225.33 ms 19.16 ms
6aab859 1245.14 ms 1247.59 ms 2.45 ms
be1723a 1253.31 ms 1267.36 ms 14.06 ms
0a23f98 1252.98 ms 1276.76 ms 23.78 ms
134c9f8 1284.48 ms 1306.18 ms 21.70 ms
7d5e695 1230.20 ms 1265.40 ms 35.20 ms
732a7b4 1242.17 ms 1266.96 ms 24.79 ms
873fb42 1261.00 ms 1285.92 ms 24.92 ms
64e4616 1242.80 ms 1270.07 ms 27.27 ms
fec92cc 1237.93 ms 1259.21 ms 21.28 ms

App size

Revision Plain With Sentry Diff
202b83f 8.33 MiB 9.40 MiB 1.07 MiB
6aab859 8.29 MiB 9.36 MiB 1.07 MiB
be1723a 8.38 MiB 9.77 MiB 1.39 MiB
0a23f98 8.10 MiB 9.18 MiB 1.08 MiB
134c9f8 8.16 MiB 9.16 MiB 1.01 MiB
7d5e695 8.38 MiB 9.74 MiB 1.36 MiB
732a7b4 8.32 MiB 9.38 MiB 1.06 MiB
873fb42 8.16 MiB 9.17 MiB 1.01 MiB
64e4616 8.28 MiB 9.34 MiB 1.05 MiB
fec92cc 8.33 MiB 9.54 MiB 1.22 MiB

Previous results on branch: feat/replay-bitmap-transfer

Startup times

Revision Plain With Sentry Diff
9d6fbb7 1241.18 ms 1268.17 ms 26.99 ms
69e689c 1247.09 ms 1260.71 ms 13.62 ms
7f1fbf4 1245.69 ms 1273.43 ms 27.73 ms

App size

Revision Plain With Sentry Diff
9d6fbb7 8.42 MiB 9.89 MiB 1.46 MiB
69e689c 8.42 MiB 9.89 MiB 1.46 MiB
7f1fbf4 8.42 MiB 9.89 MiB 1.46 MiB

@vaind vaind changed the title enha: replay: don't convert to PNG when transferring to native enha: replay: use rawRGBA for replay native integration on ios Jan 13, 2025
@vaind vaind marked this pull request as ready for review January 14, 2025 13:21
Copy link
Contributor

@buenaflor buenaflor left a comment

Choose a reason for hiding this comment

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

👍

@vaind vaind merged commit a43c400 into main Jan 14, 2025
57 of 58 checks passed
@vaind vaind deleted the feat/replay-bitmap-transfer branch January 14, 2025 18:06
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.

2 participants