Crash Reporting

Crash Reporting

The Applause SDK will automatically handle uncaught exceptions from your application and send them to the Applause SDK server. When your app crashes, the Applause SDK will record the relevant information and then send the data to the server the next time the app starts.

If you are deploying a build to the App Store, or you’ve removed the symbols from your build, you will also need to upload a special symbols file to the Mobile SDK so that it can symbolicate your crashes. Symbolication is the process by which the Mobile SDK adds human readable symbol names back to the stack traces for builds which have had their symbols removed. The process of prepping a symbol file for a build is easy, and you can read the instructions in the  Symbolication help article.

Exception Handlers

The Applause SDK automatically records crashes from your application by instructingNSSetUncaughtExceptionHandler to send all uncaught exceptions to the Applause SDK method: APLUncaughtExceptionHandler:

extern void APLUncaughtExceptionHandler(NSException* exception);

Working with the Applause Exception Handler

If you use NSSetUncaughtExceptionHandler by yourself and still would like to report crashes to Appplause SDK, simply call our handler from inside the  function registered for uncaught exceptions.

Example

Let’s say you have your exception handler defined as so, you need to do the following:

void MyUncaughtExceptionHandler(NSException* exception) {
    //Do your stuff here
    APLUncaughtExceptionHandler(exception);
}

If you have correctly configured the uncaught exception handler, then your app will automatically log crashes to the Applause SDK.