Page MenuHomePhabricator

Gather mw.loader.store (localStorage) statistics from users
Open, LowPublic

Description

We know that people hit the limit, probably due to ResourceLoader, but we don't know how often that happens. Going forward, even if we move RL's cache out of localStorage, we need to have visibility on real world usage of localStorage. Ideally we would not only track when users hit the limit, but also get statistics on what is taking up the space.

I think this is particularly important as 3rd-party JS libraries or even gadgets could also be consuming localStorage space without us noticing.

Event Timeline

Gilles created this task.Sep 2 2015, 6:08 AM
Gilles raised the priority of this task from to Normal.
Gilles updated the task description. (Show Details)
Gilles added subscribers: Aklapper, Florian, Jdlrobson and 29 others.
TheDJ awarded a token.Sep 2 2015, 7:51 AM

As a quick start, we can add tracking of localStorage to asset-check. That'll give us insight into the default/deterministic use of localStorage on major wikis. We already track this for cookies.

This would account for all mw.loader.store data for modules loaded by default, and any values set by gadgets/scripts on load.

Getting RUM telemetry would even better since many values are only set later during real user interaction. Perhaps using EventLogging, or more light-weight using the existing statsv beacon (would need to extend wgWMEStatsdBaseUri/wikimediaEvents.statsd to support gauge in addition to timing and counter).

He7d3r awarded a token.Sep 3 2015, 7:37 PM
Krinkle set Security to None.
ori lowered the priority of this task from Normal to Lowest.Sep 10 2015, 7:36 PM
He7d3r rescinded a token.Sep 11 2015, 1:02 AM
He7d3r awarded a token.
Krinkle renamed this task from Gather localStorage usage statistics from users to [Research] Gather localStorage usage statistics from users.Dec 22 2015, 3:35 AM
Krinkle raised the priority of this task from Lowest to Normal.Jan 11 2016, 8:16 PM
Krinkle removed a subscriber: wikibugs-l-list.
Catrope removed a subscriber: Catrope.Jan 15 2016, 11:13 PM

This task is about gathering data about how much of the available storage capacity is used. E.g. how many keys or how many bytes. It is not about whether a browser supports localStorage.

Peter added a subscriber: Peter.May 2 2016, 5:29 PM
Krinkle assigned this task to Peter.Dec 6 2016, 12:27 AM
Krinkle renamed this task from [Research] Gather localStorage usage statistics from users to Gather mw.loader.store (localStorage) statistics from users.Jul 12 2017, 4:31 AM
Krinkle edited projects, added MediaWiki-ResourceLoader; removed JavaScript.
Krinkle added a subscriber: StudiesWorld.
Krinkle lowered the priority of this task from Normal to Low.Apr 6 2019, 8:24 PM