StorageActivityService causes wake-ups every 5 minutes while Firefox is completely idle
Categories
(Core :: Storage: localStorage & sessionStorage, defect, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox113 | --- | fixed |
People
(Reporter: florian, Assigned: florian)
References
(Blocks 2 open bugs)
Details
Attachments
(1 file)
These timers are visible in long profiles of Firefox being idle (eg. https://share.firefox.dev/3kueUlv).
The repeating timer is created at https://searchfox.org/mozilla-central/rev/a3a9112d4d73d1323eabbc7faa9937cd9aae6465/dom/storage/StorageActivityService.cpp#211-213
If I understand the code correctly, it is used to cleanup data that has expired after 24 hours.
Instead of this repeating timer, could we instead have a one-shot timer set to fire the next time something needs to expire?
Or if this is only to remove data from memory and because it seems the data is small, could we instead cleanup when the data is accessed? Unless I missed something, the accesses are only calls to nsIStorageActivityService.getActiveOrigins
. I found 2 callers and neither of them seems to be a hot code path.
We could also clean-up on the idle-daily observer notification.
Updated•1 year ago
|
Assignee | ||
Comment 1•1 year ago
|
||
Updated•1 year ago
|
Pushed by fqueze@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/3e80bc563a82 Cleanup expired origins in StorageActivityService on the idle-daily notification and when accessing the data instead of with a 5 minutes repeating timer, r=asuth.
Comment 3•1 year ago
|
||
bugherder |
Description
•