Skip to content

Conversation

@alwx
Copy link
Contributor

@alwx alwx commented Dec 4, 2025

📢 Type of change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring

📜 Description

Updates metrics to be processed correctly.
In addition to that, updates some of the tests that were incorrectly using content type for logs.

💚 How did you test it?

Tests, tests, tests. And just running the app and seing myself.

📝 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

#skip-changelog

@github-actions
Copy link
Contributor

github-actions bot commented Dec 4, 2025

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

Generated by 🚫 dangerJS against e0cac1d

@alwx alwx changed the title feat(metrics): Updates Metrics code to make them being processed correctly feat(metrics): Updates Metrics code to make Metrics being processed correctly Dec 4, 2025
@alwx alwx changed the title feat(metrics): Updates Metrics code to make Metrics being processed correctly feat(metrics): Updates Metrics code to correctly process envelops withapplication/vnd.sentry.items.trace-metric+json content type Dec 5, 2025
@alwx alwx marked this pull request as ready for review December 5, 2025 09:09
Copy link
Contributor

@antonis antonis left a comment

Choose a reason for hiding this comment

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

Awesome @alwx 🚀
I've retested with the sample app and was able to see metrics on the dashboard :)

Image

Added a comment on a linter issue but other than that LGTM.
Let's also investigate @lucas-zimerman comment before merging 🙇

@lucas-zimerman
Copy link
Collaborator

@sentry review

Comment on lines 194 to +196
bytesPayload = itemPayload;
} else {
bytesContentType = 'application/vnd.sentry.items.log+json';
bytesContentType = typeof itemHeader.content_type === 'string' ? itemHeader.content_type : 'application/json';

This comment was marked as outdated.

@lucas-zimerman lucas-zimerman added the ready-to-merge Triggers the full CI test suite label Dec 5, 2025
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.

Thank you for the PR! once we fix the linting/build issues, we could merge the PR :D

@github-actions
Copy link
Contributor

github-actions bot commented Dec 5, 2025

Android (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 496.84 ms 533.70 ms 36.86 ms
Size 43.75 MiB 48.07 MiB 4.32 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
818a608 495.84 ms 498.08 ms 2.25 ms
20d5eaa 377.62 ms 406.50 ms 28.88 ms
459a438+dirty 417.09 ms 406.52 ms -10.57 ms
7480abe+dirty 411.60 ms 405.81 ms -5.78 ms
8e653ac+dirty 360.28 ms 372.04 ms 11.76 ms
6fee48d+dirty 407.42 ms 437.71 ms 30.29 ms
98f632c 424.25 ms 435.48 ms 11.23 ms
e76d0d3+dirty 404.18 ms 411.53 ms 7.35 ms
93137d1+dirty 400.15 ms 424.74 ms 24.59 ms
7be1f99 454.83 ms 461.36 ms 6.53 ms

App size

Revision Plain With Sentry Diff
818a608 17.75 MiB 19.68 MiB 1.94 MiB
20d5eaa 17.75 MiB 20.15 MiB 2.41 MiB
459a438+dirty 17.75 MiB 19.70 MiB 1.95 MiB
7480abe+dirty 17.75 MiB 19.68 MiB 1.94 MiB
8e653ac+dirty 17.75 MiB 19.75 MiB 2.00 MiB
6fee48d+dirty 17.75 MiB 19.68 MiB 1.94 MiB
98f632c 17.75 MiB 20.15 MiB 2.41 MiB
e76d0d3+dirty 17.75 MiB 19.71 MiB 1.96 MiB
93137d1+dirty 17.75 MiB 19.70 MiB 1.95 MiB
7be1f99 17.75 MiB 20.15 MiB 2.41 MiB

@github-actions
Copy link
Contributor

github-actions bot commented Dec 5, 2025

Android (new) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 578.23 ms 629.72 ms 51.49 ms
Size 43.94 MiB 48.90 MiB 4.96 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
88890fe+dirty 328.30 ms 319.85 ms -8.45 ms
c1573b3+dirty 355.65 ms 448.82 ms 93.17 ms
2104bb9+dirty 313.00 ms 309.76 ms -3.24 ms
1d62dde+dirty 366.59 ms 408.80 ms 42.21 ms
8a4ce6f+dirty 401.11 ms 381.92 ms -19.19 ms
c4e097a+dirty 382.43 ms 443.77 ms 61.34 ms
46da307+dirty 356.62 ms 415.02 ms 58.40 ms
8e653ac+dirty 304.49 ms 308.84 ms 4.35 ms
e2fa43d+dirty 326.56 ms 372.88 ms 46.32 ms
07808fb+dirty 392.47 ms 451.94 ms 59.47 ms

App size

Revision Plain With Sentry Diff
88890fe+dirty 7.15 MiB 8.44 MiB 1.28 MiB
c1573b3+dirty 7.15 MiB 8.42 MiB 1.27 MiB
2104bb9+dirty 7.15 MiB 8.46 MiB 1.30 MiB
1d62dde+dirty 7.15 MiB 8.46 MiB 1.31 MiB
8a4ce6f+dirty 7.15 MiB 8.41 MiB 1.26 MiB
c4e097a+dirty 7.15 MiB 8.41 MiB 1.26 MiB
46da307+dirty 7.15 MiB 8.41 MiB 1.26 MiB
8e653ac+dirty 7.15 MiB 8.46 MiB 1.31 MiB
e2fa43d+dirty 7.15 MiB 8.42 MiB 1.27 MiB
07808fb+dirty 7.15 MiB 8.43 MiB 1.28 MiB

@alwx
Copy link
Contributor Author

alwx commented Dec 5, 2025

@lucas-zimerman that's done now

@alwx alwx requested a review from lucas-zimerman December 5, 2025 13:57
@github-actions
Copy link
Contributor

github-actions bot commented Dec 5, 2025

iOS (new) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1209.00 ms 1218.17 ms 9.17 ms
Size 3.41 MiB 4.67 MiB 1.25 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
b7aa1aa+dirty 1232.55 ms 1234.16 ms 1.61 ms
128ee72+dirty 1204.73 ms 1205.02 ms 0.29 ms
8d20c8e+dirty 1223.60 ms 1223.87 ms 0.27 ms
fdbea8b+dirty 1196.19 ms 1212.09 ms 15.90 ms
46bd012+dirty 1231.78 ms 1212.30 ms -19.47 ms
b80b14f+dirty 1193.79 ms 1199.12 ms 5.33 ms
3099014+dirty 1234.04 ms 1243.22 ms 9.18 ms
f70acbf+dirty 1239.00 ms 1242.53 ms 3.53 ms
8ff81c0+dirty 1219.51 ms 1221.66 ms 2.15 ms
b3b5b0d+dirty 1235.16 ms 1238.61 ms 3.45 ms

App size

Revision Plain With Sentry Diff
b7aa1aa+dirty 3.19 MiB 4.58 MiB 1.39 MiB
128ee72+dirty 3.41 MiB 4.58 MiB 1.17 MiB
8d20c8e+dirty 3.41 MiB 4.57 MiB 1.16 MiB
fdbea8b+dirty 3.41 MiB 4.59 MiB 1.18 MiB
46bd012+dirty 3.19 MiB 4.38 MiB 1.19 MiB
b80b14f+dirty 3.41 MiB 4.59 MiB 1.18 MiB
3099014+dirty 3.19 MiB 4.55 MiB 1.36 MiB
f70acbf+dirty 3.19 MiB 4.54 MiB 1.36 MiB
8ff81c0+dirty 3.41 MiB 4.59 MiB 1.18 MiB
b3b5b0d+dirty 3.19 MiB 4.48 MiB 1.29 MiB

@github-actions
Copy link
Contributor

github-actions bot commented Dec 5, 2025

iOS (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1213.12 ms 1215.94 ms 2.81 ms
Size 3.41 MiB 4.67 MiB 1.25 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
b7aa1aa+dirty 1234.35 ms 1241.61 ms 7.27 ms
128ee72+dirty 1218.16 ms 1219.18 ms 1.03 ms
8d20c8e+dirty 1216.62 ms 1220.31 ms 3.69 ms
fdbea8b+dirty 1210.38 ms 1211.96 ms 1.57 ms
46bd012+dirty 1220.49 ms 1226.89 ms 6.40 ms
b80b14f+dirty 1212.62 ms 1211.73 ms -0.89 ms
3099014+dirty 1226.75 ms 1236.56 ms 9.81 ms
f70acbf+dirty 1235.71 ms 1243.14 ms 7.43 ms
8ff81c0+dirty 1209.17 ms 1206.15 ms -3.02 ms
b3b5b0d+dirty 1227.71 ms 1239.50 ms 11.79 ms

App size

Revision Plain With Sentry Diff
b7aa1aa+dirty 2.63 MiB 4.01 MiB 1.38 MiB
128ee72+dirty 3.41 MiB 4.58 MiB 1.17 MiB
8d20c8e+dirty 3.41 MiB 4.57 MiB 1.16 MiB
fdbea8b+dirty 3.41 MiB 4.59 MiB 1.18 MiB
46bd012+dirty 2.63 MiB 3.81 MiB 1.18 MiB
b80b14f+dirty 3.41 MiB 4.59 MiB 1.18 MiB
3099014+dirty 2.63 MiB 3.98 MiB 1.35 MiB
f70acbf+dirty 2.63 MiB 3.98 MiB 1.34 MiB
8ff81c0+dirty 3.41 MiB 4.59 MiB 1.18 MiB
b3b5b0d+dirty 2.63 MiB 3.91 MiB 1.28 MiB

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-merge Triggers the full CI test suite

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants