Aaron Schulz has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/178591

Change subject: Simplified profiler config
......................................................................

Simplified profiler config

Change-Id: I3e75b32871825ec05694443a79032ae2a8853267
---
M wmf-config/StartProfiler.php
1 file changed, 6 insertions(+), 18 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/91/178591/1

diff --git a/wmf-config/StartProfiler.php b/wmf-config/StartProfiler.php
index 7fa084d..a65549e 100644
--- a/wmf-config/StartProfiler.php
+++ b/wmf-config/StartProfiler.php
@@ -5,21 +5,13 @@
 
 # Non-logged profiling for debugging
 if ( isset( $_REQUEST['forceprofile'] ) ) {
-       if ( defined( 'HHVM_VERSION' ) ) {
-               $wgProfiler['class'] = 'ProfilerXhprof';
-               $wgProfiler['flags'] = XHPROF_FLAGS_NO_BUILTINS;
-       } else {
-               $wgProfiler['class'] = 'ProfilerStandard';
-       }
+       $wgProfiler['class'] = 'ProfilerXhprof';
+       $wgProfiler['flags'] = XHPROF_FLAGS_NO_BUILTINS;
        $wgProfiler['output'] = 'text';
 # Profiling hack for test2 wiki (not sampled, but shouldn't distort too much)
 } elseif ( isset( $_SERVER['HTTP_HOST'] ) && $_SERVER['HTTP_HOST'] === 
'test2.wikipedia.org' ) {
-       if ( defined( 'HHVM_VERSION' ) ) {
-               $wgProfiler['class'] = 'ProfilerXhprof';
-               $wgProfiler['flags'] = XHPROF_FLAGS_CPU | XHPROF_FLAGS_MEMORY | 
XHPROF_FLAGS_NO_BUILTINS;
-       } else {
-               $wgProfiler['class'] = 'ProfilerStandard';
-       }
+       $wgProfiler['class'] = 'ProfilerXhprof';
+       $wgProfiler['flags'] = XHPROF_FLAGS_CPU | XHPROF_FLAGS_MEMORY | 
XHPROF_FLAGS_NO_BUILTINS;
        $wgProfiler['output'] = 'udp';
        $wgProfiler['profileID'] = 'test2';
 # Normal case: randomly (or not) selected for logged profiling sample
@@ -39,12 +31,8 @@
                $wgProfiler['profileID'] = $version;
        }
 } elseif ( $wmfRealm === 'labs' ) {
-       if ( defined( 'HHVM_VERSION' ) ) {
-               $wgProfiler['class'] = 'ProfilerXhprof';
-               $wgProfiler['flags'] = XHPROF_FLAGS_CPU | XHPROF_FLAGS_MEMORY | 
XHPROF_FLAGS_NO_BUILTINS;
-       } else {
-               $wgProfiler['class'] = 'ProfilerStandard';
-       }
+       $wgProfiler['class'] = 'ProfilerXhprof';
+       $wgProfiler['flags'] = XHPROF_FLAGS_CPU | XHPROF_FLAGS_MEMORY | 
XHPROF_FLAGS_NO_BUILTINS;
        $wgProfiler['output'] = 'udp';
        $coreGit = new GitInfo( $IP );
        $wgProfiler['profileID'] = $coreGit->getHeadSHA1() ?: 'labs';

-- 
To view, visit https://gerrit.wikimedia.org/r/178591
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3e75b32871825ec05694443a79032ae2a8853267
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to