Hi all,

Wikimedia's production configuration of MediaWiki supports enabling request
profiling, to obtain call-graphs, flame graphs, and other useful details
about the PHP execution.

In production, this can be enabled by using the WikimediaDebug browser
extension. For instructions see

Until now, none of these profiling modes were available on the Beta Cluster.

As of today, the "Plaintext request profile" is supported on Beta Cluster.
This profile can be obtained by adding ?forceprofile=1 to any web request,
and making sure the X-Wikimedia-Debug header is set.

To make this easier to enable from a web browser, the WikimediaDebug
browser extension was updated (WikimediaDebug v1.9.1) to also send
X-Wikimedia-Debug headers on Beta Cluster requests. (For the time being,
the backend host names are ignored for Beta Cluster requests, this is a
future to-do.)

Example from cURL:

$ curl -H 'X-Wikimedia-Debug: 1' '

Fr those with shell access, it can also be used on maintenance scripts (in
production, or in the Beta Cluster) by setting PHP=hhvm before the mwscript
command and adding the --profiler=text option.

-- Timo

[0] https://phabricator.wikimedia.org/T180766
Wikitech-l mailing list

Reply via email to