Instapaper creator points out app caching flaw in iOS 5

Cached items now periodically cleaned out

Marco Arment, the creator of Instapaper, has written a blog post about an emerging problem caused by a change in the way iOS 5 does housekeeping: it now periodically clears out the "Caches" and "tmp" directories that some "offline reading" and map apps use for storing content, meaning apps will need to re-downloaded the content that has been removed -- potentially costing users in 3G data, or inconvenience when they are offline.

The reasoning behind the change in iOS 5 is sound; the cleaning isn't triggered until an iOS device begins to run too low on space (the exact definition of that known only to Apple) and thus removes what it considers are (or should be) temporary items to reclaim space in those situations. Content that was "cleaned" but is needed again can simply be re-downloaded. Cleaning out temporary files can also be considered a security improvement.

The problem arises, however, if needed content can't be re-downloaded -- either because the user is no longer connected to the internet, or because the only download option is using 3G, which most users have strict limits on. Long articles, large maps, downloadable graphic novels, alternative podcasts not handled by iTunes and offline Wikipedia apps, as examples, now have to put their data in the "Caches" directory, which will be deleted without the user's knowledge when the device gets too full, making them think the app was to blame for lost content.

The only alternative -- placing the data in the app's internal "Documents" directory -- means the large files will be periodically and automatically synced with iCloud, which may use up 3G data and will count against a user's 5GB of storage. Apple has begun "cracking down" on apps that try to store too much data in the "Documents" directory. As Arment explains, "There needs to be a file storage location that behaves the way Caches did before iOS 5: it's not backed up to iTunes or iCloud, it's not synced, but it's also never deleted unless the app is deleted."

Although he does not specify it, Arment and other developers have undoubtedly been in conversation with Apple about the changes in iOS 5 since before its public release (it went through an extensive beta period). A solution may be forthcoming, but Arment complains that in the meantime, users are going to be upset with apps and developers rather than Apple, even though the issue was created by a system change. This may increase support requests and cause other problems, including an eroded user experience for users who routinely keep their iDevice relatively full. [Photo of Marco Arment via Lucius Kwok]

  1. aristotles 10/14, 12:55am

    This is a PEBCAK (problem exists between chair and Keyboard) issue. Simply don't sync too much onto your device and you will not run into this issue.

    Leave a few gigs free after you sync and you should be fine.

  1. darkelf 10/14, 02:37am

    i'm failing to see the problem here. any system requires some free space to work well. if your device is that low on storage, NOT trashing something may cause bigger problems than having to download some c*** again.

  1. DoctorGonzo 10/14, 02:46am

    This is not good news.

  1. simdude 10/14, 07:37am

    I see no problem with storing in the apps documents area. You have options in the iCloud backup setting to pick which apps data get backed up. Just uncheck Instapaper and it doesn't get backed up to the iCloud. It's a temporary reading app anyway. If you didn't back it up and the iPhone got trashed, you just restore and redownload the content. You have to get an internet connection anyway to restore so what exactly is the problem here?

  1. malax 10/14, 09:43am

    Simdude's got it right. What part of "cache" or "tmp" suggest "persistent storage that doesn't get deleted when space is needed for other things."

  1. testudo 10/14, 02:53pm

    Simdude's got it right. What part of "cache" or "tmp" suggest "persistent storage that doesn't get deleted when space is needed for other things."

    Nothing. But Apple offers no alternatives. It's either 'cache', which means it can go away and you're complaining that app x is continually downloading the same content over and over again, costing you data usage, or 'document', which means it's going to icloud, and then you're whining about how they're taking up all the space in your iCloud folder and costing you data usage.

    The guy isn't complaining as a developer, he's making the comment as a warning to users and other developers of the potential for unforseen consequences.

    But, I know, it sounds like he's knocking Apple, so it's time to knock the guy down.

Login Here

Not a member of the MacNN forums? Register now for free.