Page MenuHomePhabricator

Add a feature to clean up all the cache and offline data
Open, NormalPublic

Description

In T201879, we found some articles' offline data will not be removed if we delete the articles from reading lists.

Although we have a patch to solve that issue, the existing "junk" offline data will be still remaining in the app as user data.

To solve that, we can provide a feature (a button) with a warning message to clear all the cache data in cache -> okhttp-cache and files -> okhttp-cache

Event Timeline

cooltey created this task.Nov 8 2018, 9:40 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptNov 8 2018, 9:40 PM
Dbrant added a subscriber: Dbrant.Nov 20 2018, 9:03 PM

Another idea we discussed is to create a periodic automated task that actually checks for orphan files in the cache directories. (i.e. query reading list pages from the database, and physically check the cache contents for each page)

Have an idea that does the following steps:

  1. Query all pages
  2. Check the valid caches and move the caches to a temp folder
  3. Clean up the cache folder
  4. Move the files inside temp folder back to the cache folder.
Charlotte triaged this task as Normal priority.Apr 18 2019, 11:43 AM

@Charlotte
After discussing with engineers, we think it would be better if we move this ticket to the N board since we are all not sure about what is the best way of implementing it.

Seems reasonable @cooltey - I will leave in the N backlog till you've identified a way forward.