You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+6-1Lines changed: 6 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,11 @@
5
5
### Features
6
6
7
7
- Add `installGroupsOverride` parameter to Build Distribution SDK for programmatic filtering, with support for configuration via properties file using `io.sentry.distribution.install-groups-override` ([#5066](https://github.com/getsentry/sentry-java/pull/5066))
8
+
- Add new experimental option to capture profiles for ANRs ([#4899](https://github.com/getsentry/sentry-java/pull/4899))
9
+
- This feature will capture a stack profile of the main thread when it gets unresponsive
10
+
- The profile gets attached to the ANR event on the next app start, providing a flamegraph of the ANR issue on the sentry issue details page
11
+
- Breaking change: if the ANR stacktrace contains only system frames (e.g. `java.lang` or `android.os`), a static fingerprint is set on the ANR event, causing all ANR events to be grouped into a single issue, reducing the overall ANR issue noise
12
+
- Enable via `options.setEnableAnrProfiling(true)` or Android manifest: `<meta-data android:name="io.sentry.anr.enable-profiling" android:value="true" />`
8
13
9
14
### Dependencies
10
15
@@ -106,7 +111,7 @@
106
111
- Discard envelopes on `4xx` and `5xx` response ([#4950](https://github.com/getsentry/sentry-java/pull/4950))
107
112
- This aims to not overwhelm Sentry after an outage or load shedding (including HTTP 429) where too many events are sent at once
108
113
109
-
### Feature
114
+
### Features
110
115
111
116
- Add a Tombstone integration that detects native crashes without relying on the NDK integration, but instead using `ApplicationExitInfo.REASON_CRASH_NATIVE` on Android 12+. ([#4933](https://github.com/getsentry/sentry-java/pull/4933))
112
117
- Currently exposed via options as an _internal_ API only.
Copy file name to clipboardExpand all lines: sentry-android-core/api/sentry-android-core.api
+80Lines changed: 80 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -364,6 +364,7 @@ public final class io/sentry/android/core/SentryAndroidOptions : io/sentry/Sentr
364
364
public fun isCollectExternalStorageContext ()Z
365
365
public fun isEnableActivityLifecycleBreadcrumbs ()Z
366
366
public fun isEnableActivityLifecycleTracingAutoFinish ()Z
367
+
public fun isEnableAnrProfiling ()Z
367
368
public fun isEnableAppComponentBreadcrumbs ()Z
368
369
public fun isEnableAppLifecycleBreadcrumbs ()Z
369
370
public fun isEnableAutoActivityLifecycleTracing ()Z
@@ -392,6 +393,7 @@ public final class io/sentry/android/core/SentryAndroidOptions : io/sentry/Sentr
392
393
public fun setDebugImagesLoader (Lio/sentry/android/core/IDebugImagesLoader;)V
393
394
public fun setEnableActivityLifecycleBreadcrumbs (Z)V
394
395
public fun setEnableActivityLifecycleTracingAutoFinish (Z)V
396
+
public fun setEnableAnrProfiling (Z)V
395
397
public fun setEnableAppComponentBreadcrumbs (Z)V
396
398
public fun setEnableAppLifecycleBreadcrumbs (Z)V
397
399
public fun setEnableAutoActivityLifecycleTracing (Z)V
@@ -546,6 +548,84 @@ public final class io/sentry/android/core/ViewHierarchyEventProcessor : io/sentr
546
548
public static fun snapshotViewHierarchyAsData (Landroid/app/Activity;Lio/sentry/util/thread/IThreadChecker;Lio/sentry/ISerializer;Lio/sentry/ILogger;)[B
547
549
}
548
550
551
+
public class io/sentry/android/core/anr/AggregatedStackTrace {
552
+
public fun <init> ([Ljava/lang/StackTraceElement;IIJF)V
553
+
public fun addOccurrence (J)V
554
+
public fun getStack ()[Ljava/lang/StackTraceElement;
555
+
}
556
+
557
+
public class io/sentry/android/core/anr/AnrCulpritIdentifier {
558
+
public fun <init> ()V
559
+
public static fun identify (Ljava/util/List;)Lio/sentry/android/core/anr/AggregatedStackTrace;
560
+
public static fun isSystemFrame (Ljava/lang/String;)Z
561
+
}
562
+
563
+
public class io/sentry/android/core/anr/AnrException : java/lang/Exception {
564
+
public fun <init> ()V
565
+
public fun <init> (Ljava/lang/String;)V
566
+
}
567
+
568
+
public class io/sentry/android/core/anr/AnrProfile {
569
+
public final field endtimeMs J
570
+
public final field stacks Ljava/util/List;
571
+
public final field startTimeMs J
572
+
public fun <init> (Ljava/util/List;)V
573
+
}
574
+
575
+
public class io/sentry/android/core/anr/AnrProfileManager : java/io/Closeable {
576
+
public fun <init> (Lio/sentry/SentryOptions;)V
577
+
public fun <init> (Lio/sentry/SentryOptions;Ljava/io/File;)V
578
+
public fun add (Lio/sentry/android/core/anr/AnrStackTrace;)V
579
+
public fun clear ()V
580
+
public fun close ()V
581
+
public fun load ()Lio/sentry/android/core/anr/AnrProfile;
582
+
}
583
+
584
+
public class io/sentry/android/core/anr/AnrProfileRotationHelper {
585
+
public fun <init> ()V
586
+
public static fun deleteLastFile (Ljava/io/File;)Z
587
+
public static fun getFileForRecording (Ljava/io/File;)Ljava/io/File;
588
+
public static fun getLastFile (Ljava/io/File;)Ljava/io/File;
589
+
public static fun rotate ()V
590
+
}
591
+
592
+
public class io/sentry/android/core/anr/AnrProfilingIntegration : io/sentry/Integration, io/sentry/android/core/AppState$AppStateListener, java/io/Closeable, java/lang/Runnable {
593
+
public static final field POLLING_INTERVAL_MS J
594
+
public static final field THRESHOLD_ANR_MS J
595
+
public fun <init> ()V
596
+
protected fun checkMainThread (Ljava/lang/Thread;)V
597
+
public fun close ()V
598
+
protected fun getProfileManager ()Lio/sentry/android/core/anr/AnrProfileManager;
599
+
protected fun getState ()Lio/sentry/android/core/anr/AnrProfilingIntegration$MainThreadState;
600
+
public fun onBackground ()V
601
+
public fun onForeground ()V
602
+
public fun register (Lio/sentry/IScopes;Lio/sentry/SentryOptions;)V
603
+
public fun run ()V
604
+
}
605
+
606
+
protected final class io/sentry/android/core/anr/AnrProfilingIntegration$MainThreadState : java/lang/Enum {
607
+
public static final field ANR_DETECTED Lio/sentry/android/core/anr/AnrProfilingIntegration$MainThreadState;
608
+
public static final field IDLE Lio/sentry/android/core/anr/AnrProfilingIntegration$MainThreadState;
609
+
public static final field SUSPICIOUS Lio/sentry/android/core/anr/AnrProfilingIntegration$MainThreadState;
610
+
public static fun valueOf (Ljava/lang/String;)Lio/sentry/android/core/anr/AnrProfilingIntegration$MainThreadState;
611
+
public static fun values ()[Lio/sentry/android/core/anr/AnrProfilingIntegration$MainThreadState;
612
+
}
613
+
614
+
public final class io/sentry/android/core/anr/AnrStackTrace : java/lang/Comparable {
615
+
public final field stack [Ljava/lang/StackTraceElement;
616
+
public final field timestampMs J
617
+
public fun <init> (J[Ljava/lang/StackTraceElement;)V
618
+
public fun compareTo (Lio/sentry/android/core/anr/AnrStackTrace;)I
619
+
public synthetic fun compareTo (Ljava/lang/Object;)I
620
+
public static fun deserialize (Ljava/io/DataInputStream;)Lio/sentry/android/core/anr/AnrStackTrace;
621
+
public fun serialize (Ljava/io/DataOutputStream;)V
622
+
}
623
+
624
+
public final class io/sentry/android/core/anr/StackTraceConverter {
625
+
public fun <init> ()V
626
+
public static fun convert (Lio/sentry/android/core/anr/AnrProfile;)Lio/sentry/protocol/profiling/SentryProfile;
627
+
}
628
+
549
629
public final class io/sentry/android/core/cache/AndroidEnvelopeCache : io/sentry/cache/EnvelopeCache {
550
630
public static final field LAST_ANR_MARKER_LABEL Ljava/lang/String;
551
631
public static final field LAST_ANR_REPORT Ljava/lang/String;
0 commit comments