The support forum is temporarily read-only. For urgent requests, please email contact[at]psyberia.net

[closed] Cache Management - Selective Tile Deletion

Any question about the app? Ask it here
Post Reply
Yemble
Posts: 333
Joined: Sun Apr 28, 2013 5:02 pm

[closed] Cache Management - Selective Tile Deletion

Post by Yemble »

Having the ability to create large offline map caches is great, but they can consume a large chunk of precious SD card capacity. It would be nice to have some control over the growth of these caches, over and above removing the entire lot... especially given the amount of time it takes to build them!

May I suggest utilising the existing Store Area code, but rather than it determining the area to download, instead it defines the area to make selective cached tile deletions from. In this mode, the zoom level bar would dictate the tiles to be RETAINED. Tiles beyond the selected zoom scales would then be removed from the cache.

I realise that previously allocated SQL 2Gb extent files would not be removed, but space would be released within them for tiles cached in the future.

Alternatively, why not just add an option on the download dialog to prune tiles from non-selected zoom levels, within the chosen area. As you have already written 90% of the code, I reckon that this should be reasonably easy to implement.
Psyberia-Support
Site Admin
Posts: 6407
Joined: Wed Apr 14, 2010 9:41 pm

Re: Cache Management - Selective Tile Deletion

Post by Psyberia-Support »

Hi,
I have studied this feature with interest.
It's true that it could be nice to have a cleanup feature, as the storage is right now only increasing.
My first idea was to add a "cleanup" function that would delete all tiles older than x months (I though about 6). I haven't done it yet since I have to make a important technical decision: either to simply mark old tiles as pruned (so ready to be overwritten), or to make a full copy of the cache data and ignoring old tiles.
The first choice (which seems to be the one you thought about) requires more work since it needs an updated list of pruned tiles, and will add an extra time when writing tiles (to check if the list contains a suitable empty space).
The second one is simpler, would allow the cache storage to shrink, but has to be manually started by the user and could require a long time (and needs a large empty space).
In any case, the ability of removing selected areas or scales could be easily added.
I'll now work on the waiting features for the next version, but then I'll try to think about that.
Best regards
Do you like AlpineQuest ? Leave a small comment on Google Play !
Post Reply