Prepare Android Release Build for Appxiom SDK
To ensure accurate monitoring and error reporting in your production app, follow these best practices when preparing your Android release build with Appxiom SDK:
- Exclude log() API from execution in release builds to avoid unnecessary debug data in production.
- Add Proguard rules as specified to prevent obfuscation issues and preserve stacktrace details for error analysis.
Application Class Example
- Java
- Kotlin
public class BlogApp extends Application {
@Override
public void onCreate() {
super.onCreate();
Ax.init(this, appKey, platformKey);
}
}
class BlogApp: Application() {
override fun onCreate() {
super.onCreate()
Ax.init(this, appKey, platformKey)
}
}
Always back up the mapping file for each production build. This file is required to deobfuscate stacktraces in the Appxiom dashboard and accurately analyze production crashes.
Location of mapping file:
project-folder/app/build/outputs/mapping/release/mapping.txt