You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 25, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 25, 2023. It is now read-only.
Should we implement a download manager which automates the process of caching all the tiles within a bounding box? How would that work? Would it be enough if the only API calls are "cache all the tiles in {MKCoordinateRegion} for {mapID}" and "clear the cache for {mapID}", or does it need to support multiple separate, and possibly overlapping, regions in order to be useful? The first case seems pretty reasonable, but the second one might take a lot of work.
For some context, see MBXCacheManager from issue #61 (the code is here).
One complicating thought though would be how to handle updating a cached map if the update doesn't complete before a network connection is lost. It would be bad to have a mix of old and new tiles in the cache, and you wouldn't want to clear the cache and risk having no tiles present either.
I'd love an atomic update capability that would download all the map tiles in a region to a certain depth, and only if the download fully succeeds then clear the cache and replace it with the new data.
The usage scenarios I have in mind are for apps that are used primarily offline or with very marginal net connectivity, and it is important to never break functionality if a user tries to update her maps and the connection fails or never finishes.
My current plan is to embed a starting map inside the apps via MBTiles, and I've been puzzling over how to allow for OTA updates without requiring a full new version of the app to be released. This might be a way.
does it need to support multiple separate, and possibly overlapping, regions in order to be useful
I would say no. The SDK has had the single region capability for a couple years and I've never heard of someone needing particular distinct regions within it (on a per-mapID basis, anyway).
Activity
radven commentedon Mar 5, 2014
I like this idea.
One complicating thought though would be how to handle updating a cached map if the update doesn't complete before a network connection is lost. It would be bad to have a mix of old and new tiles in the cache, and you wouldn't want to clear the cache and risk having no tiles present either.
I'd love an atomic update capability that would download all the map tiles in a region to a certain depth, and only if the download fully succeeds then clear the cache and replace it with the new data.
The usage scenarios I have in mind are for apps that are used primarily offline or with very marginal net connectivity, and it is important to never break functionality if a user tries to update her maps and the connection fails or never finishes.
My current plan is to embed a starting map inside the apps via MBTiles, and I've been puzzling over how to allow for OTA updates without requiring a full new version of the app to be released. This might be a way.
radven commentedon Mar 5, 2014
I think only a single region would be fine - I'm trying to imagine cases it wouldn't be.
incanus commentedon Mar 7, 2014
I would say no. The SDK has had the single region capability for a couple years and I've never heard of someone needing particular distinct regions within it (on a per-
mapIDbasis, anyway).