Repository navigation
[not ready] Make Annotations API threadsafe - #1022
Conversation
|
Thanks for the flag @kkaefer. I think this will be an easy lift as the
|
|
Specifically, |
|
👍 Good call. |
|
@incanus One option to avoid uv_async::send would be to expose an interface similar to NSObject.performSelectorOnMainThread in mbgl::Map class. This would allow such code to be added without any changes to the Map class. |
|
I was chatting about that very approach with @kkaefer; we may get there eventually. |
|
@kkaefer will be taking a look at shoring this up. |
|
Note that this change does not yet fix the actual issue of accessing the tile data and source objects from both threads. |
|
@incanus Can we remove the shared pointer use in |
|
We have solid improvements across the board here, but still not a fix for the core threading problem. |
|
@kkaefer What's your ETA look like for the actual threading fixes here? I think we should get these improvements at they stand now over into |
|
Per voice with @kkaefer I'm going to merge these improvements and spin out a new ticket specific to the threading issues, which we don't have a good answer on yet. We are both meditating on this 🙇 |
|
→ #1069 for the thread work-to-be. |
C++ style & safety improvements
This currently reaches into the innards of the Map objects from the main thread, which is not safe.
/cc @incanus