From: Bryan Davis Date: Mon, 17 Nov 2014 17:32:45 +0000 (-0700) Subject: Prettier wfLogProfilingData() log message X-Git-Tag: 1.31.0-rc.0~13273 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_aide%28?a=commitdiff_plain;h=0b91f622a3680bc8bee1aabe2db6a4da9d62fe2e;p=lhc%2Fweb%2Fwiklou.git Prettier wfLogProfilingData() log message Make the profiler logging output introduced in Iae11e1e a little nicer. Stop adding the Profiler::getRawData() information and add the URL and textual report to the default log message. When testing with a Monolog logger and Logstash the getRawData output from the Xhprof profiler was found to be too big to be usable. The default message output was found to be less informative than desirable when a PSR-3 logger other than MWLoggerLegacyLogger was used. MWLoggerLegacyLogger implements special backwards compatible formatting for the profileoutput channel that will not be effected by this change. Change-Id: Id326aed4f72a3489fac30661c101ac3bb3af2530 --- diff --git a/includes/GlobalFunctions.php b/includes/GlobalFunctions.php index b499904316..71c3791749 100644 --- a/includes/GlobalFunctions.php +++ b/includes/GlobalFunctions.php @@ -1226,10 +1226,9 @@ function wfLogProfilingData() { } $ctx['output'] = $profiler->getOutput(); - $ctx['profile'] = $profiler->getRawData(); $log = MWLogger::getInstance( 'profileoutput' ); - $log->info( 'Elapsed: {elapsed}', $ctx ); + $log->info( "Elapsed: {elapsed}; URL: <{url}>\n{output}", $ctx ); } /**