Page MenuHomePhabricator

MultimediaViewer processes all thumbnails on the page even when it's supposedly disabled
Open, LowestPublic

Description

When debugging T141714, I was very surprised when I turned off MultimediaViewer in my preferences (unchecked "Enable Media Viewer" on https://commons.wikimedia.org/wiki/Special:Preferences#mw-prefsection-rendering) and continued experiencing the issue. If it's not going to take over those elements, it should not be processing them.

Event Timeline

matmarex created this task.Aug 2 2016, 5:55 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptAug 2 2016, 5:55 PM
Tgr added a subscriber: Tgr.Aug 2 2016, 7:04 PM

MediaViewer still loads when disabled, to handle links that specifically request it (#/media/...). (There is a hard off flag but it's not exposed via the prefs UI.) I do not like that MV preprocesses all images on load (I think it's unnecessary, whether it's enabled or not) but that seems like a significant effort to change and I'm not sure it's worth it unless it is causing serious problems.

The registration of processThumbs could probably be moved up the call stack a bit as a quick fix.

dr0ptp4kt triaged this task as Lowest priority.Aug 4 2016, 3:16 PM
dr0ptp4kt moved this task from Incoming to 2014-15 Q4 on the Readers-Web-Backlog board.
Alsee added a subscriber: Alsee.Apr 16 2019, 4:52 PM
Alsee added a comment.EditedJul 6 2019, 8:25 PM

I do not like that MV preprocesses all images on load (I think it's unnecessary, whether it's enabled or not) but that seems like a significant effort to change and I'm not sure it's worth it unless it is causing serious problems.

Well let's do the math. We serve eighteen billion page views per month (as of 2016 anyway), and any patch may be relevant for the next decade or two. By my math each one millisecond we trim from page load works out to.... approximately 100 years spent preprocessing images. Given that people tend to live less than a hundred years, and that people spend about 1/3 of their lives asleep, each one millisecond has a value of approximately two entire human lives.

Perhaps someone could provide info on how much time, on average, MV spends preprocessing images on a page load.

Tgr removed a subscriber: Tgr.Jul 9 2019, 6:05 PM