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

Use isolates to encode features #367

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

T-moz
Copy link

@T-moz T-moz commented Jan 13, 2024

Fixes #366

Wrapping jsonEncode in a compute allow data encoding without blocking the main isolate.
BUT
Spawning multiple isolate is very expensive, and can lead to crash.
So this technique is better used when encoding multiple geojsonFeature.


Currently, I have a performance issues on my app, when updating multiple lines.
So I coded a fix that solves only this issue.
But this principle could be applied to symbols, circles, polygones, and to the method setGeoJsonSource.

I willing to work on this, but first, I need review and feedbacks on this first implementation 🙏.

@T-moz T-moz marked this pull request as draft January 13, 2024 18:15
@T-moz T-moz force-pushed the use-isolates-for-encoding-features branch from 7028d44 to 6f34e48 Compare January 14, 2024 14:50
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.

Performance issue - Main isolate is blocked when encoding geojsonFeature
1 participant