Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(node): Allow Anr worker to be stopped and restarted #11214

Merged
merged 1 commit into from Mar 21, 2024

Conversation

timfish
Copy link
Collaborator

@timfish timfish commented Mar 20, 2024

With the Electron SDK, we have an issue (getsentry/sentry-electron#830) where ANR causes the app to freeze when the machine goes through a suspend/resume cycle.

This PR exposes stopWorker and startWorker methods which can be used in the downstream ANR integration wrapper to stop the ANR feature before device suspend and start it again on device resume.

This comment was marked as off-topic.

@timfish timfish marked this pull request as ready for review March 21, 2024 12:42
Copy link
Member

@AbhiPrasad AbhiPrasad left a comment

Choose a reason for hiding this comment

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

Nice! should we backport to v7?

@AbhiPrasad AbhiPrasad merged commit be09f89 into develop Mar 21, 2024
63 checks passed
@AbhiPrasad AbhiPrasad deleted the timfish/feat/anr-allow-stop-start branch March 21, 2024 15:48
@AbhiPrasad AbhiPrasad mentioned this pull request Mar 21, 2024
AbhiPrasad pushed a commit that referenced this pull request Mar 21, 2024
This was missed from the original PR #11214 but is already included in
the backport #11228
c298lee pushed a commit that referenced this pull request Mar 22, 2024
This was missed from the original PR #11214 but is already included in
the backport #11228
cadesalaberry pushed a commit to cadesalaberry/sentry-javascript that referenced this pull request Apr 19, 2024
…1214)

With the Electron SDK, we have an issue
(getsentry/sentry-electron#830) where ANR
causes the app to freeze when the machine goes through a suspend/resume
cycle.

This PR exposes `stopWorker` and `startWorker` methods which can be used
in the downstream [ANR integration
wrapper](https://github.com/getsentry/sentry-electron/blob/master/src/main/integrations/anr.ts)
to stop the ANR feature before device suspend and start it again on
device resume.
cadesalaberry pushed a commit to cadesalaberry/sentry-javascript that referenced this pull request Apr 19, 2024
This was missed from the original PR getsentry#11214 but is already included in
the backport getsentry#11228
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants