Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 10 Next »


The AMPLIFY Crash Analytics monitors crash reports from Titanium applications.

Currently, the AMPLIFY Crash Analytics only supports the Android and iOS platforms.

Using AMPLIFY Crash Analytics

To use the AMPLIFY Crash Analytics, enable Services for your project, then use the AMPLIFY Crash Analytics module API to add breadcrumbs, user metadata and error handling code to log events leading up to a crash. Login to the AMPLIFY Dashboard and use the AMPLIFY Crash Analytics dashboard to analyze crash reports.

Setup Your Project

When creating a new application in Appcelerator Studio, make sure the Enable Appcelerator Services check box is enabled.

For a previously created project, if Appcelerator Services were not previously enabled, open your tiapp.xml file, then click the Enable Services button under the Appcelerator Service section.

Appcelerator Studio injects code into the tiapp.xml file to set up the AMPLIFY Crash Analytics module ( com.appcelerator.aca ).

Initialize the Module

Once com.appcelerator.aca has been added to the tiapp.xml, the module will initialize automatically on startup.

However, to access module methods, you will need to require the module:

Create a Breadcrumb Trail

To make it easier to track the events leading up to a crash, use the leaveBreadcrumb method to add breadcrumbs in your code. Place breadcrumbs near events and application state changes to track problematic paths that can lead to an application crash. Append variables to your breadcrumbs to track their state. For example:

These breadcrumbs are collected and passed to the AMPLIFY Crash Analytics.

Add User Metadata

Use the setUsername and setMetadata methods to differentiate users of your application when viewing reports on the AMPLIFY Crash Analytics dashboard. For example:

By default, a username is not included. The username appears with the crash or error reports.

Log An Error

You can track handled errors in your application by passing a JavaScript Error object to the logHandledException method, which can help identify and analyze potential errors and hot spots. For example:

Error logs are useful for tracking crashes in third-party SDKs, code that syncs data between services, or detecting bad data that is returned from a server.

Allow the User to Opt-Out

Use the setOptOutStatus method to allow the user NOT to send any information to the AMPLIFY Crash Analytics. Passing true to this method disables sending data to AMPLIFY Crash Analytics.

Check for a Crash

Use the didCrashOnLastAppLoad method to check if the application crashed in a previous session. If the method returns true, the application crashed on the last session.

  • No labels