Stop unnecessary serialization of symbol source features. #7013
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes issue #7012.
This data is expensive to serialize and isn't even being used.
I did a brief manual check to see that this didn't break anything. I'm still not sure why this was here in the first place, but I think it's (1) vestigial, and (2) got more expensive as part of adding expressions.
None of our benchmarks exercise the tile serialization pathway, but I did some quick-and-dirty benchmarking by zooming from 7 to 16 and back twice (40 seconds total animation) and counting frames. For each recording 600 == no dropped frames. The first run is presumably slower because the tiles are being loaded for the first time instead of from cache.
Before
562
594
600
598
After
563
594
589
597
🤷♂️ Not much of a difference? Let me try to focus on just first load since we'd expect the difference to mainly be there:
Before
562
558
562
534
-> 46 dropped frame avg
After
563
567
570
565
-> 34 dropped frame avg
If I squint enough that looks like a win!
Launch Checklist
write tests for all new functionalitydocument any changes to public APIstagged@mapbox/studio
and/or@mapbox/maps-design
if this PR includes style spec changes/cc @mourner @anandthakker @ansis