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

Android SurfaceView shutdowns may be causing ANRs #2848

Open
sjg-wdw opened this issue Sep 18, 2024 · 0 comments
Open

Android SurfaceView shutdowns may be causing ANRs #2848

sjg-wdw opened this issue Sep 18, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@sjg-wdw
Copy link
Collaborator

sjg-wdw commented Sep 18, 2024

We have a difficult (so far impossible) to reproduce bug that's resulting in a lot of stakeholder crashes.

The problem appears to be one GLSurfaceView shutting down while another is running.
This shouldn't be a problem, but there might be a set of really obscure cases where it takes a while for one to pass through the wait() logic if another one is rendering.

The change we'd like is to make the GLThreadManager in MapboxGLSurfaceView a local object. There's no apparent need for it to be global. In theory each surface view should be able to negotiate its own shutdown with its own objects and not need to coordinate with the others.

Yeah, in theory. So we'll want to test that pretty heavily. There's a mode in the Android test app that creates and destroys surface views as you scroll around. Try that for testing.

@sjg-wdw sjg-wdw added the bug Something isn't working label Sep 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants