Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/trailbehind/tboomdetector
Detect Out Of Memory events in an iOS app
https://github.com/trailbehind/tboomdetector
crash-reporting ios memory oom
Last synced: 3 days ago
JSON representation
Detect Out Of Memory events in an iOS app
- Host: GitHub
- URL: https://github.com/trailbehind/tboomdetector
- Owner: trailbehind
- License: mit
- Created: 2015-09-01T20:59:11.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2022-03-07T17:25:51.000Z (over 2 years ago)
- Last Synced: 2024-04-24T21:01:16.278Z (7 months ago)
- Topics: crash-reporting, ios, memory, oom
- Language: Objective-C
- Size: 30.3 KB
- Stars: 48
- Watchers: 23
- Forks: 9
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# TBOOMDetector
Detect Out Of Memory events in an iOS app by process of elimination. If we can't figure out why the app is relaunching, it must have been the OOM Killer. For a complete explanation read [this excellent blog post from Facebook](https://code.facebook.com/posts/1146930688654547/reducing-fooms-in-the-facebook-ios-app/).
Requires crashlytics for detecting crashes.
Example:
```objc
TBOOMDetector *oomDetector = [[TBOOMDetector alloc] initWithDirectory:directory
crashCheck:^BOOL{
// return [[Crashlytics crashlytics] didCrashDuringPreviousExecution]
return NO;
}
callback:^(TBTerminationType terminationType) {
if(terminationType == TBTerminationTypeBackgroundOom) {
DDLogError(@"Detected Background OOM");
} else if(terminationType == TBTerminationTypeForegroundOom) {
DDLogError(@"Detected Foreground OOM");
}
}];
```