X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=StartProfiler.sample;h=bdf21396e2d7e5bbf55eb50950df95bc36f32eb7;hp=6681b870cf33ded39bdb8fc2245e9153f56e1d1f;hb=ebc5cca3181d19c4ed488ba78cd3a39446dcb055;hpb=579d6e75554610c03d1096d61bf1d4b2f680468c diff --git a/StartProfiler.sample b/StartProfiler.sample index 6681b870cf..bdf21396e2 100644 --- a/StartProfiler.sample +++ b/StartProfiler.sample @@ -4,30 +4,35 @@ * To use a profiler, copy this file to StartProfiler.php and add: * $wgProfiler['class'] = 'ProfilerXhprof'; * - * For output, add: - * $wgProfiler['output'] = array( 'text' ); - * 'text' can be one (or more) of 'text' 'udp' 'db' or 'dump' - * 'db' requires creating the profiling table, see patch-profiling.sql + * For output, set the 'output' key to an array of class names, one for each + * output type you want the profiler to generate. For example: + * $wgProfiler['output'] = array( 'ProfilerOutputText' ); * - * The 'text' output will be added to the output page in a comment approriate - * to the output's mime type. For a text/html page, this display can be - * changed to a preformatted text block by setting the 'visible' configuration - * flag: + * The output classes available to you by default are ProfilerOutputDb, + * ProfilerOutputDump, ProfilerOutputStats, ProfilerOutputText, and + * ProfilerOutputUdp. + * + * ProfilerOutputStats outputs profiling data as StatsD metrics. It expects + * that you have set the $wgStatsdServer configuration variable to the host (or + * host:port) of your statsd server. + * + * ProfilerOutputText will output profiling data in the page body as a comment. + * You can make the profiling data in HTML render as part of the page content + * by setting the 'visible' configuration flag: * $wgProfiler['visible'] = true; * - * The 'db' output expects a database table that can be created by applying + * 'ProfilerOutputDb' expects a database table that can be created by applying * maintenance/archives/patch-profiling.sql to your database. * - * The 'dump' output expects a $wgProfiler['outputDir'] telling it where to + * 'ProfilerOutputDump' expects a $wgProfiler['outputDir'] telling it where to * write dump files. The files produced are compatible with the XHProf gui. - * * For a rudimentary sampling profiler: * $wgProfiler['class'] = 'ProfilerXhprof'; - * $wgProfiler['output'] = array( 'db' ); + * $wgProfiler['output'] = array( 'ProfilerOutputDb' ); * $wgProfiler['sampling'] = 50; // one every 50 requests * This will use ProfilerStub for non-sampled cases. * - * For performance, the profiler is always disabled for CLI scripts - * as they could be long running and the data would accumulate. Use - * the --profiler parameter of maintenance scripts to override this. + * For performance, the profiler is always disabled for CLI scripts as they + * could be long running and the data would accumulate. Use the '--profiler' + * parameter of maintenance scripts to override this. */