Closed Bug 1058934 Opened 11 years ago Closed 5 years ago

Delete DOMStorage for marketplace.firefox.com

Categories

(Firefox for Android Graveyard :: General, defect, P5)

defect

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: rnewman, Unassigned)

References

Details

A user shared their 104MB webappsstore.sqlite with me in Bug 857888. In it I spotted the following: moc.xoferif.ecalptekram.:https:443 0::model_cache 1376262 Yup, that's 1.3MB of cached data. The contents are two rows like this: {"app":{"traghetti":{"author":"Vincenzo Bonanno","banner_message":null,"banner_regions":[],"categories":["travel","maps-navigation"],"content_ratings":{"body":"pegi","rating":"3","interactives":[],"descriptors":[]},"current_version":"1.0","description":"Prenotazione traghetti online, offerte, tariffe e orari traghetti, aliscafi e navi per la Sardegna, la Grecia, la Sicilia, l'Isola d'Elba, la Croazia, la Corsica, Ischia e le Eolie.\n\nCon questa APP puoi prenotare i biglietti dei traghetti per la Sardegna, la Corsica, l'Isola d'Elba, la Sicilia, l'Isola del Giglio, le Isole Pontine, le Tremiti, gli Aliscafi Eolie, aliscafi Capri, traghetti Ischia, Procida, Ancona, Portoferraio, Malta, traghetti Olbia e per i paesi che si affacciano sul mediterraneo quali Francia, Spagna, Croazia, Grecia, traghetti per Tunisi e Marocco. \n\nLa procedura è semplice e intuitiva poichè il sistema di prenotazione è stato costruito in modo da renderti il percorso di consultazione e di acquisto sicuro, fac webappsstore/DOMStorage doesn't get expired or evicted; that 1.3MB sticks around forever. This is particularly concerning on Android, where that 1.3MB might well be enough to prevent an update from installing, or will throw storage errors that will cause the user to uninstall Firefox. I'd like to see that brought down under 50KB — maybe skip or truncate the description in each app? Maybe don't persist them in DOMStorage at all? Maybe Marketplace now uses IndexedDB; if so, I'd love to see it clean up DOMStorage.
Thanks for filing. We cap our request/model cache at 4 MB and we do expire stale data: https://github.com/mozilla/fireplace/blob/master/src/media/js/settings.js#L71-L81 The benchmarks we did showed that, because of the startup cost of loading the database, IndexedDB was in fact slower than using localStorage. Admittedly, we should lower that limit. After rolling out the new feed design today, there is less usage of localStorage for caching. I believe people are revisiting this system.
cvan's comment suggested there's going to be drop in this data with feed, Kevin is that the case?
Flags: needinfo?(kngo)
Yes, the Feed is slimmer since we don't request fully deserialized apps. And the feed itself only uses one layer of caching (request cache) rather than two (request + model cache).
Flags: needinfo?(kngo)
Can we find out how much it takes up now and see if its ok?
Flags: needinfo?(kngo)
Priority: -- → P3
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → WONTFIX
Whiteboard: [marketplace-transition]
See Also: → 857888
Might as well reopen this as a cleanup bug, because it's not okay to spew a meg of data onto a user's phone and leave it there for all time.
Status: RESOLVED → REOPENED
Flags: needinfo?(kngo)
Priority: P3 → --
Product: Marketplace → Firefox for Android
Resolution: WONTFIX → ---
Summary: marketplace.firefox.com uses 1.3MB of DOMStorage → Delete DOMStorage for marketplace.firefox.com
Whiteboard: [marketplace-transition]
Version: Avenir → Trunk
If desktop wants this too, feel free to move this bug into Core.
Status: REOPENED → NEW
Re-triaging per https://bugzilla.mozilla.org/show_bug.cgi?id=1473195 Needinfo :susheel if you think this bug should be re-triaged.
Priority: -- → P5
We have completed our launch of our new Firefox on Android. The development of the new versions use GitHub for issue tracking. If the bug report still reproduces in a current version of [Firefox on Android nightly](https://play.google.com/store/apps/details?id=org.mozilla.fenix) an issue can be reported at the [Fenix GitHub project](https://github.com/mozilla-mobile/fenix/). If you want to discuss your report please use [Mozilla's chat](https://wiki.mozilla.org/Matrix#Connect_to_Matrix) server https://chat.mozilla.org and join the [#fenix](https://chat.mozilla.org/#/room/#fenix:mozilla.org) channel.
Status: NEW → RESOLVED
Closed: 10 years ago5 years ago
Resolution: --- → INCOMPLETE
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.