Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
028f17b
feat: merge tombstone and native sdk events
supervacuus Jan 19, 2026
6befa43
add preliminary change log
supervacuus Jan 19, 2026
aa8f65f
Merge branch 'main' into feat/tombstone_native_sdk_merge
supervacuus Jan 23, 2026
bf14914
Merge branch 'main' into feat/tombstone_native_sdk_merge
supervacuus Jan 23, 2026
d7d5447
add preliminary change log
supervacuus Jan 21, 2026
ba1bfc7
apply review+sync feedback
supervacuus Jan 23, 2026
7d73c41
Merge branch 'main' into feat/tombstone_native_sdk_merge
supervacuus Jan 27, 2026
cd970cb
add tombstone manifest flag
supervacuus Jan 28, 2026
b832e7c
remove tombstone-native correlation via processStateSummary
supervacuus Jan 28, 2026
df83d57
2-phase streaming NativeEventCollector (#5065)
supervacuus Jan 29, 2026
e6f6788
Merge branch 'main' into feat/tombstone_native_sdk_merge
supervacuus Jan 29, 2026
0ba1f6a
Merge branch 'main' into feat/tombstone_native_sdk_merge
supervacuus Feb 2, 2026
00c5839
Merge branch 'main' into feat/tombstone_native_sdk_merge
supervacuus Feb 2, 2026
72d5644
extract inner inApp check into a reusable static method
supervacuus Feb 3, 2026
2fd6b28
reduce I/O in the collect() method of the NativeEventCollector.
supervacuus Feb 3, 2026
c3be389
add native attachments to TombstoneHint.
supervacuus Feb 3, 2026
c8dafdd
introduce VMA -> module coalescing via ModuleAccumulator
supervacuus Feb 3, 2026
f20587a
ensure native crash survives the merge
supervacuus Feb 3, 2026
011008d
handle null nativeLibraryDir in TombstoneParser
supervacuus Feb 3, 2026
423145d
clarify inApp vs nativeLibraryDir usage in code comment
supervacuus Feb 3, 2026
03ac8a6
Merge branch 'main' into feat/tombstone_native_sdk_merge
supervacuus Feb 5, 2026
f028319
ignore stack frames from anonymous VMAs that don't resolve to a funct…
supervacuus Feb 5, 2026
0ec2068
use the right nativeLibraryDir for the tombstone test fixture
supervacuus Feb 5, 2026
aeeacd2
add proguard rule for protobuf-lite
supervacuus Feb 6, 2026
017ac5f
make BoundedInputStream safer wrt double closes
supervacuus Feb 6, 2026
67aee7b
override empty function name behavior from SentryStackTraceFactory.is…
supervacuus Feb 6, 2026
555a2d3
Merge branch 'main' into feat/tombstone_native_sdk_merge
markushi Feb 6, 2026
3a78d01
Merge branch 'refs/heads/main' into feat/tombstone_native_sdk_merge
supervacuus Feb 6, 2026
3e3fc73
pre merge preps.
supervacuus Feb 6, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.DS_Store
.java-version
.idea/
.gradle/
.run/
Expand Down
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,20 @@
sentry:
enable-database-transaction-tracing: true
```
- Add support for collecting native crashes using Tombstones ([#4933](https://github.com/getsentry/sentry-java/pull/4933), [#5037](https://github.com/getsentry/sentry-java/pull/5037))
- Added Tombstone integration that detects native crashes using `ApplicationExitInfo.REASON_CRASH_NATIVE` on Android 12+
- Crashes enriched with Tombstones contain more crash details and detailed thread info
- Tombstone and NDK integrations are now automatically merged into a single crash event, eliminating duplicate reports
- To enable it, add the integration in your Sentry initialization:
```kotlin
SentryAndroid.init(context, options -> {
options.isTombstoneEnabled = true
})
```
or in the `AndroidManifest.xml` using:
```xml
<meta-data android:name="io.sentry.tombstone.enable" android:value="true" />
```

### Fixes

Expand Down
15 changes: 14 additions & 1 deletion sentry-android-core/api/sentry-android-core.api
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,19 @@ public final class io/sentry/android/core/LoadClass : io/sentry/util/LoadClass {
public fun loadClass (Ljava/lang/String;Lio/sentry/ILogger;)Ljava/lang/Class;
}

public final class io/sentry/android/core/NativeEventCollector {
public fun <init> (Lio/sentry/android/core/SentryAndroidOptions;)V
public fun collect ()V
public fun deleteNativeEventFile (Lio/sentry/android/core/NativeEventCollector$NativeEventData;)Z
public fun findAndRemoveMatchingNativeEvent (J)Lio/sentry/android/core/NativeEventCollector$NativeEventData;
}

public final class io/sentry/android/core/NativeEventCollector$NativeEventData {
public fun getEnvelope ()Lio/sentry/SentryEnvelope;
public fun getEvent ()Lio/sentry/SentryEvent;
public fun getFile ()Ljava/io/File;
}

public final class io/sentry/android/core/NdkHandlerStrategy : java/lang/Enum {
public static final field SENTRY_HANDLER_STRATEGY_CHAIN_AT_START Lio/sentry/android/core/NdkHandlerStrategy;
public static final field SENTRY_HANDLER_STRATEGY_DEFAULT Lio/sentry/android/core/NdkHandlerStrategy;
Expand Down Expand Up @@ -500,7 +513,7 @@ public final class io/sentry/android/core/TombstoneIntegration$TombstoneHint : i
}

public class io/sentry/android/core/TombstoneIntegration$TombstonePolicy : io/sentry/android/core/ApplicationExitInfoHistoryDispatcher$ApplicationExitInfoPolicy {
public fun <init> (Lio/sentry/android/core/SentryAndroidOptions;)V
public fun <init> (Lio/sentry/android/core/SentryAndroidOptions;Landroid/content/Context;)V
public fun buildReport (Landroid/app/ApplicationExitInfo;Z)Lio/sentry/android/core/ApplicationExitInfoHistoryDispatcher$Report;
public fun getLabel ()Ljava/lang/String;
public fun getLastReportedTimestamp ()Ljava/lang/Long;
Expand Down
4 changes: 4 additions & 0 deletions sentry-android-core/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@

-keepnames class io.sentry.android.core.ApplicationNotResponding

# protobuf-java lite
# https://github.com/protocolbuffers/protobuf/blob/5d876c9fec1a6f2feb0750694f803f89312bffff/java/lite.md#r8-rule-to-make-production-app-builds-work
-keep class * extends com.google.protobuf.GeneratedMessageLite { *; }

##---------------End: proguard configuration for android-core ----------

##---------------Begin: proguard configuration for sentry-apollo-3 ----------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,7 @@ static void initializeIntegrationsAndProcessors(
if (options.getSocketTagger() instanceof NoOpSocketTagger) {
options.setSocketTagger(AndroidSocketTagger.getInstance());
}

if (options.getPerformanceCollectors().isEmpty()) {
options.addPerformanceCollector(new AndroidMemoryCollector());
options.addPerformanceCollector(new AndroidCpuCollector(options.getLogger()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ final class ManifestMetadataReader {
static final String ANR_TIMEOUT_INTERVAL_MILLIS = "io.sentry.anr.timeout-interval-millis";
static final String ANR_ATTACH_THREAD_DUMPS = "io.sentry.anr.attach-thread-dumps";

static final String TOMBSTONE_ENABLE = "io.sentry.tombstone.enable";

static final String AUTO_INIT = "io.sentry.auto-init";
static final String NDK_ENABLE = "io.sentry.ndk.enable";
static final String NDK_SCOPE_SYNC_ENABLE = "io.sentry.ndk.scope-sync.enable";
Expand Down Expand Up @@ -205,6 +207,8 @@ static void applyMetadata(
}

options.setAnrEnabled(readBool(metadata, logger, ANR_ENABLE, options.isAnrEnabled()));
options.setTombstoneEnabled(
readBool(metadata, logger, TOMBSTONE_ENABLE, options.isTombstoneEnabled()));

// use enableAutoSessionTracking as fallback
options.setEnableAutoSessionTracking(
Expand Down
Loading
Loading