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

Fix: Set the correct OOM event timestamp #2394

Merged
merged 3 commits into from
Nov 16, 2022

Conversation

kevinrenskers
Copy link
Contributor

@kevinrenskers kevinrenskers commented Nov 16, 2022

📜 Description

Use the last breadcrumb's timestamp as the OOM event timestamp

💡 Motivation and Context

Fixes #2383

💚 How did you test it?

Unit tests, and ran the sample app, creating an OOM and waiting a few minutes before starting the app again. The OOM event has the correct timestamp: https://sentry.io/organizations/sentry-sdks/issues/2291658301/?project=5428557&query=is%3Aunresolved&referrer=issue-stream.

📝 Checklist

  • I reviewed the submitted code
  • I added tests to verify the changes
  • I updated the docs if needed
  • Review from the native team if needed
  • No breaking changes

🔮 Next steps

Copy link
Member

@philipphofmann philipphofmann left a comment

Choose a reason for hiding this comment

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

LGTM

@github-actions
Copy link

github-actions bot commented Nov 16, 2022

Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1225.90 ms 1247.62 ms 21.72 ms
Size 20.75 KiB 374.39 KiB 353.64 KiB

Baseline results on branch: master

Startup times

Revision Plain With Sentry Diff
09ad77e 1242.14 ms 1244.02 ms 1.88 ms
6177f2d 1206.55 ms 1226.20 ms 19.65 ms
347a8e9 1243.50 ms 1265.90 ms 22.40 ms
ef8b0ce 1212.34 ms 1249.64 ms 37.30 ms
8607e67 1213.53 ms 1238.20 ms 24.67 ms
0fdf0b2 1249.20 ms 1254.08 ms 4.88 ms
5025d2e 1245.14 ms 1268.58 ms 23.44 ms
ee127f4 1203.49 ms 1231.28 ms 27.79 ms
2ce5819 1258.02 ms 1271.94 ms 13.92 ms
c2a9b60 1222.10 ms 1240.62 ms 18.52 ms

App size

Revision Plain With Sentry Diff
09ad77e 20.50 KiB 339.01 KiB 318.51 KiB
6177f2d 20.51 KiB 332.90 KiB 312.40 KiB
347a8e9 20.51 KiB 333.16 KiB 312.65 KiB
ef8b0ce 20.50 KiB 337.71 KiB 317.20 KiB
8607e67 20.50 KiB 338.99 KiB 318.49 KiB
0fdf0b2 20.51 KiB 332.90 KiB 312.39 KiB
5025d2e 20.51 KiB 331.79 KiB 311.28 KiB
ee127f4 20.51 KiB 333.10 KiB 312.59 KiB
2ce5819 20.50 KiB 337.76 KiB 317.26 KiB
c2a9b60 20.50 KiB 333.54 KiB 313.04 KiB

Previous results on branch: fix/2383-use-correct-OOM-timestamp

Startup times

Revision Plain With Sentry Diff
92b8904 1240.35 ms 1273.40 ms 33.06 ms

App size

Revision Plain With Sentry Diff
92b8904 20.75 KiB 374.39 KiB 353.64 KiB

@kevinrenskers kevinrenskers merged commit 8442084 into master Nov 16, 2022
@kevinrenskers kevinrenskers deleted the fix/2383-use-correct-OOM-timestamp branch November 16, 2022 11:45
kevinrenskers added a commit that referenced this pull request Nov 16, 2022
…ents

* master:
  Fix: Set the correct OOM event timestamp (#2394)
  test: Fix SentrySerializationTests.testSerializationFailsWithInvalidJSONObject (#2392)
  feat(hybrid-sdks): Add captureScreenshots to PrivateSDKOnly (#2384)
  ci: Increase test timeout for iOS 12 (#2391)
  test: Disable flaky testCrashReportCount1 (#2389)
  test: Disable flaky testSerializeWithUnderlyingNSException (#2387)
kevinrenskers added a commit that referenced this pull request Nov 22, 2022
* 8.0.0:
  ref: Fix typos in OOMTracker (#2431)
  ref: Make SpanProtocol.data non nullable (#2409)
  ref: add/improve logging (#2420)
  ref: bump supported OS versions (#2414)
  test: shorten some tests (#2428)
  ref: Remove `- [SentryOptions initWithDict:didFailWithError:]` (#2404)
  ref: Mark [SpanProtocol setExtraValue:forKey] as deprecated (#2413)
  typos (#2421)
  test: Disable NSDataTracker in clearTestState (#2418)
  Update CHANGELOG.md (#2415)
  feat: Properly demangle Swift class name (#2162)
  chore: Create 8.0.0 branch
  test: include Sentry changes in hash keys (#2412)
  release: 7.31.2
  fix: Crash in Client when reading integrations (#2398)
  test: tooling improvements (#2400)
  fix: Don't increase session's error count for dropped events (#2374)
  Update CHANGELOG.md (#2396)
  release: 7.31.1
  Fix: Set the correct OOM event timestamp (#2394)

# Conflicts:
#	Sentry.xcodeproj/project.pbxproj
#	SentryPrivate.podspec
#	scripts/add-sentry-to-vlc.patch
kevinrenskers added a commit that referenced this pull request Nov 24, 2022
* master: (56 commits)
  meta: disable swiftlint file length check in TBDBClient.swift (#2435)
  Revert "test: shorten some tests (#2422)" (#2427)
  test: shorten some tests (#2422)
  test: include Sentry changes in hash keys (#2412)
  release: 7.31.2
  fix: Crash in Client when reading integrations (#2398)
  test: tooling improvements (#2400)
  fix: Don't increase session's error count for dropped events (#2374)
  Update CHANGELOG.md (#2396)
  release: 7.31.1
  Fix: Set the correct OOM event timestamp (#2394)
  test: Fix SentrySerializationTests.testSerializationFailsWithInvalidJSONObject (#2392)
  feat(hybrid-sdks): Add captureScreenshots to PrivateSDKOnly (#2384)
  ci: Increase test timeout for iOS 12 (#2391)
  test: Disable flaky testCrashReportCount1 (#2389)
  test: Disable flaky testSerializeWithUnderlyingNSException (#2387)
  build(deps): bump github/codeql-action from 2.1.31 to 2.1.32 (#2386)
  build(deps): bump fastlane from 2.210.1 to 2.211.0 (#2385)
  ref: json serialization error reporting (#2355)
  release: 7.31.0
  ...
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.

Wrong timestamp for OOM event and breadcrumbs
2 participants