-
-
Notifications
You must be signed in to change notification settings - Fork 267
enh: use lifecycle hook for before send event #3017
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
base: main
Are you sure you want to change the base?
enh: use lifecycle hook for before send event #3017
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3017 +/- ##
==========================================
- Coverage 87.88% 87.70% -0.18%
==========================================
Files 287 287
Lines 9780 9792 +12
==========================================
- Hits 8595 8588 -7
- Misses 1185 1204 +19 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
iOS Performance metrics 🚀
|
Revision | Plain | With Sentry | Diff |
---|---|---|---|
0fb45d0 | 1273.24 ms | 1286.44 ms | 13.19 ms |
dbd526b | 1244.78 ms | 1259.02 ms | 14.24 ms |
73dca78 | 1246.65 ms | 1265.42 ms | 18.76 ms |
73a3c38 | 1263.37 ms | 1277.90 ms | 14.53 ms |
6ba4675 | 1223.12 ms | 1238.17 ms | 15.04 ms |
93b7728 | 1247.23 ms | 1264.87 ms | 17.64 ms |
6f47800 | 1247.52 ms | 1259.37 ms | 11.85 ms |
640ad0c | 1241.04 ms | 1253.96 ms | 12.92 ms |
b6c8720 | 1252.65 ms | 1266.61 ms | 13.96 ms |
2d34233 | 1258.19 ms | 1268.92 ms | 10.73 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
0fb45d0 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
dbd526b | 7.86 MiB | 9.44 MiB | 1.58 MiB |
73dca78 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
73a3c38 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
6ba4675 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
93b7728 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
6f47800 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
640ad0c | 7.86 MiB | 9.44 MiB | 1.58 MiB |
b6c8720 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
2d34233 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
Previous results on branch: enhancements/use-lifecycle-hook-before-send-event
Startup times
Revision | Plain | With Sentry | Diff |
---|---|---|---|
4e720b9 | 1265.15 ms | 1272.98 ms | 7.83 ms |
9d51684 | 1245.62 ms | 1249.02 ms | 3.40 ms |
6eda8bd | 1262.18 ms | 1267.09 ms | 4.90 ms |
6650ed5 | 1262.86 ms | 1284.06 ms | 21.20 ms |
9e774c1 | 1263.31 ms | 1280.24 ms | 16.93 ms |
e052838 | 1254.76 ms | 1263.79 ms | 9.04 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
4e720b9 | 7.85 MiB | 9.45 MiB | 1.59 MiB |
9d51684 | 7.85 MiB | 9.45 MiB | 1.59 MiB |
6eda8bd | 7.86 MiB | 9.44 MiB | 1.58 MiB |
6650ed5 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
9e774c1 | 7.86 MiB | 9.44 MiB | 1.58 MiB |
e052838 | 7.85 MiB | 9.45 MiB | 1.59 MiB |
Android Performance metrics 🚀
|
Revision | Plain | With Sentry | Diff |
---|---|---|---|
79f6b41 | 469.66 ms | 525.90 ms | 56.24 ms |
2d34233 | 470.54 ms | 558.90 ms | 88.36 ms |
6f47800 | 451.04 ms | 509.64 ms | 58.60 ms |
dbd526b | 504.88 ms | 569.02 ms | 64.15 ms |
4481076 | 484.08 ms | 505.70 ms | 21.61 ms |
73a3c38 | 478.18 ms | 526.62 ms | 48.44 ms |
6ba4675 | 499.80 ms | 632.43 ms | 132.63 ms |
aeb02f2 | 373.84 ms | 437.00 ms | 63.16 ms |
73dca78 | 476.53 ms | 522.21 ms | 45.68 ms |
640ad0c | 466.00 ms | 552.67 ms | 86.67 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
79f6b41 | 6.54 MiB | 7.69 MiB | 1.15 MiB |
2d34233 | 6.54 MiB | 7.55 MiB | 1.01 MiB |
6f47800 | 6.54 MiB | 7.69 MiB | 1.15 MiB |
dbd526b | 6.54 MiB | 7.69 MiB | 1.15 MiB |
4481076 | 6.54 MiB | 7.69 MiB | 1.15 MiB |
73a3c38 | 6.54 MiB | 7.69 MiB | 1.15 MiB |
6ba4675 | 6.54 MiB | 7.53 MiB | 1015.26 KiB |
aeb02f2 | 6.54 MiB | 7.69 MiB | 1.15 MiB |
73dca78 | 6.54 MiB | 7.69 MiB | 1.15 MiB |
640ad0c | 6.54 MiB | 7.69 MiB | 1.15 MiB |
Previous results on branch: enhancements/use-lifecycle-hook-before-send-event
Startup times
Revision | Plain | With Sentry | Diff |
---|---|---|---|
9d51684 | 517.34 ms | 569.74 ms | 52.40 ms |
4e720b9 | 469.48 ms | 517.15 ms | 47.67 ms |
6eda8bd | 487.57 ms | 567.46 ms | 79.89 ms |
e052838 | 457.27 ms | 485.24 ms | 27.97 ms |
6650ed5 | 441.54 ms | 516.91 ms | 75.37 ms |
9e774c1 | 458.33 ms | 486.46 ms | 28.12 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
9d51684 | 6.54 MiB | 7.53 MiB | 1017.60 KiB |
4e720b9 | 6.54 MiB | 7.53 MiB | 1017.60 KiB |
6eda8bd | 6.54 MiB | 7.69 MiB | 1.15 MiB |
e052838 | 6.54 MiB | 7.53 MiB | 1017.60 KiB |
6650ed5 | 6.54 MiB | 7.70 MiB | 1.16 MiB |
9e774c1 | 6.54 MiB | 7.69 MiB | 1.15 MiB |
@denrase can you have a early look pls |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approach looking good to me. 👍
- Missing hint
- Not sure if we should remove the methods from the options or just deprecate them.
- CI complains about missing test coverage
we can remove them, they were never meant to be public |
test('OnBeforeCaptureLog should call the hook', () async { | ||
final hub = fixture.getSut(); | ||
|
||
hub.registerCallback<OnBeforeCaptureLog>((event) { | ||
// No-op | ||
}); | ||
|
||
final log = givenLog(); | ||
await hub.captureLog(log); | ||
|
||
expect(fixture.client.lifecycleCallbacks[OnBeforeCaptureLog]?.length, 1); | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is already tested in the client
bugbot run |
📜 Description
Now that we have sdk lifecycle hooks we can re-factor the beforeSendEvent observer that we added to implement web sessions
💡 Motivation and Context
💚 How did you test it?
📝 Checklist
sendDefaultPii
is enabled🔮 Next steps