Skip to content

feat(anr): [Non-Fatal ANR 1] Add HangManager - #6722

Open
markushi wants to merge 14 commits into
markushi/feat/non-fatal-anr-collectionfrom
markushi/feat/non-fatal-anr-1-hang-recorder
Open

markushi wants to merge 14 commits into
markushi/feat/non-fatal-anr-collectionfrom
markushi/feat/non-fatal-anr-1-hang-recorder

Conversation

@markushi

@markushi markushi commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

Foundation for Non-Fatal ANRs:

  • Adds the central HangManager and the central loop, including all required interfaces
  • The HangRecorder samples the collectors on the manager's 66 ms tick thread, and the manager gives the HangRecord to the subscribers that asked for it.
  • Not wired yet (see stacked PRs).

Design

image

See full spec for more details: Non-Fatal ANR Architecture (JAVA-777)

Example Event: https://sentry-sdks.sentry.io/issues/7865095622/events/6d88b353646b4c2d884a2180f83190d0/

image

⚠️ Merge this PR using a merge commit (not squash). Only the collection branch is squash-merged into main.

#skip-changelog

@github-actions github-actions Bot added the risk: medium PR risk score: medium label Nov 20, 2026
@github-actions

github-actions Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor

PR risk: medium

For commit c7b7e2c.

Main concerns: public contract, host performance, data sent to Sentry.

Rules that block low also fired:

  • R4: a public API record changed: sentry-android-core/api/sentry-android-core.api

This label is a hint for reviewers, not an approval.

@github-actions

github-actions Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor
Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against c7b7e2c

@sentry

sentry Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

📲 Install Builds

Android

🔗 App Name App ID Version Configuration
SDK Size io.sentry.tests.size 8.65.0 (1) release

⚙️ sentry-android Build Distribution Settings

@markushi
markushi marked this pull request as ready for review November 20, 2026 18:01
@markushi
markushi requested review from a team and adinauer as code owners November 20, 2026 18:01
@markushi
markushi requested review from 0xadam-brown and romtsn and removed request for a team November 20, 2026 18:01
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 20, 2026

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 3 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit b6952c6. Configure here.

@markushi
markushi marked this pull request as draft November 23, 2026 07:51
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 23, 2026
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 23, 2026
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 24, 2026
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 24, 2026
@markushi markushi changed the title feat(anr): [Non-Fatal ANR 1] Add HangRecorder feat(anr): [Non-Fatal ANR 1] Add HangManager Nov 24, 2026
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 24, 2026
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 24, 2026
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 24, 2026
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 24, 2026
@markushi
markushi marked this pull request as ready for review November 24, 2026 12:40
@github-actions github-actions Bot added risk: medium PR risk score: medium and removed risk: medium PR risk score: medium labels Nov 24, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk: medium PR risk score: medium

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant