Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Don't reload/reparse tiles after app gets backgrounded #1154

Closed
kkaefer opened this issue Mar 30, 2015 · 1 comment
Closed

Don't reload/reparse tiles after app gets backgrounded #1154

kkaefer opened this issue Mar 30, 2015 · 1 comment
Labels
Android Mapbox Maps SDK for Android iOS Mapbox Maps SDK for iOS performance Speed, stability, CPU usage, memory usage, or power usage refactor

Comments

@kkaefer
Copy link
Member

kkaefer commented Mar 30, 2015

We're currently reloading and reparsing the tiles once the app gets backgrounded on iOS (and Android for that matter). This is because the Style object gets deleted, which clears out all loaded tiles. While the vector tile itself is most likely cached, we still have the overhead of reparsing all of the tiles.

Instead, we should hold on to the parsed buffers as long as possible (and possibly relinquish them when we get a memory warning, see #1157) and when reloading, check whether we still have a buffer object around that matches that layer's settings.

@kkaefer kkaefer added refactor performance Speed, stability, CPU usage, memory usage, or power usage iOS Mapbox Maps SDK for iOS Android Mapbox Maps SDK for Android labels Mar 30, 2015
@jfirebaugh
Copy link
Contributor

Fixed in #1065.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Android Mapbox Maps SDK for Android iOS Mapbox Maps SDK for iOS performance Speed, stability, CPU usage, memory usage, or power usage refactor
Projects
None yet
Development

No branches or pull requests

2 participants