Page MenuHomePhabricator

Add option to put "served in 0.344 seconds" message in footer, rather than as HTML comment
Closed, DeclinedPublic

Description

Author: mike.lifeguard+bugs

Description:
Like it says on the tin.

This is useful for people who like having such things in their footers. More importantly, it might be useful when tweaking performance settings so you don't have to constantly open the page source and sift through the HTML.


Version: unspecified
Severity: enhancement

Details

Reference
bz23045

Event Timeline

bzimport raised the priority of this task from to Low.Nov 21 2014, 11:08 PM
bzimport added a project: MediaWiki-Parser.
bzimport set Reference to bz23045.
bzimport added a subscriber: Unknown Object (MLST).

Dynamic content in the footer seems like it would do bad things to cache. This also seems like a feature that would get very little use and might be better served as a live hack for sites wanting it (especially if its use will only be temporary and be only by users who are already tweaking performance).

mike.lifeguard+bugs wrote:

(In reply to comment #1)

Dynamic content in the footer seems like it would do bad things to cache.

It is in the HTML one way or another - how does it matter whether it is visible or not?

It's not a caching issue, but I really don't see the need.

It's easy to do with a little of javascript. I don't think it's really worth putting in the page.
See http://es.wikipedia.org/wiki/Usuario:Platonides/tiempos.js as an example (it replaces the logout link with that info).

During development this can be displayed in the (much more advanced) Debug toolbar via $wgDebugToolbar.

In production, this HTML comment is now a javascript variable that can be accessed to your liking from mw.config (without hacking around with comment nodes in the DOM).

mw.config.set({"wgBackendResponseTime":223,"wgHostname":"mw1217"});

I agree with Chad and don't see a need for implementing a way to display just the response time somewhere visibly rendered in the page HTML.