Skip to content

Consider using a more accurate ANR tracking implementation #1796

@vibin

Description

@vibin

Hi, i'm currently evaluating Bugsnag and Sentry and one of the differences i've observed in the SDK is that Bugsnag uses a SIGQUIT signal handler to get called by OS when ANR occurs, as opposed to Sentry, which uses the watchdog approach.

I have used https://github.com/SalomonBrys/ANR-WatchDog in production before and while it's a useful library, I saw that it reports many false-positives compared to Play Console, especially in case of ANRs in BroadcastReceivers.

SIGQUIT approach is also not perfect, though. It doesn't track background ANRs: bugsnag/bugsnag-android#1377

There's a third approach to track ANRs and Crashlytics' Alpha version seems to be using it (tracks both foreground and background ANRs): getHistoricalProcessExitReasons on Android 11 and above only, sadly.

Any thoughts?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions