Merge "VirtualRESTServiceClient management cleanups"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Wed, 24 Aug 2016 03:30:55 +0000 (03:30 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Wed, 24 Aug 2016 03:30:55 +0000 (03:30 +0000)
1  2 
includes/DefaultSettings.php

@@@ -3193,15 -3193,6 +3193,15 @@@ $wgHTMLFormAllowTableFormat = true
   */
  $wgUseMediaWikiUIEverywhere = false;
  
 +/**
 + * Whether to label the store-to-database-and-show-to-others button in the editor
 + * as "Save page"/"Save changes" if false (the default) or, if true, instead as
 + * "Publish page"/"Publish changes".
 + *
 + * @since 1.28
 + */
 +$wgEditButtonPublishNotSave = false;
 +
  /**
   * Permit other namespaces in addition to the w3.org default.
   *
@@@ -8042,13 -8033,9 +8042,13 @@@ $wgJobRunRate = 1
   * When $wgJobRunRate > 0, try to run jobs asynchronously, spawning a new process
   * to handle the job execution, instead of blocking the request until the job
   * execution finishes.
 + *
   * @since 1.23
   */
 -$wgRunJobsAsync = true;
 +$wgRunJobsAsync = (
 +      !function_exists( 'register_postsend_function' ) &&
 +      !function_exists( 'fastcgi_finish_request' )
 +);
  
  /**
   * Number of rows to update per job
@@@ -8263,11 -8250,29 +8263,29 @@@ $wgPageLanguageUseDB = false
  
  /**
   * Global configuration variable for Virtual REST Services.
-  * Parameters for different services are to be declared inside
-  * $wgVirtualRestConfig['modules'], which is to be treated as an associative
-  * array. Global parameters will be merged with service-specific ones. The
-  * result will then be passed to VirtualRESTService::__construct() in the
-  * module.
+  *
+  * Use the 'path' key to define automatically mounted services. The value for this
+  * key is a map of path prefixes to service configuration. The later is an array of:
+  *   - class : the fully qualified class name
+  *   - options : map of arguments to the class constructor
+  * Such services will be available to handle queries under their path from the VRS
+  * singleton, e.g. MediaWikiServices::getInstance()->getVirtualRESTServiceClient();
+  *
+  * Auto-mounting example for Parsoid:
+  *
+  * $wgVirtualRestConfig['paths']['/parsoid/'] = [
+  *     'class' => 'ParsoidVirtualRESTService',
+  *     'options' => [
+  *         'url' => 'http://localhost:8000',
+  *         'prefix' => 'enwiki',
+  *         'domain' => 'en.wikipedia.org'
+  *     ]
+  * ];
+  *
+  * Parameters for different services can also be declared inside the 'modules' value,
+  * which is to be treated as an associative array. The parameters in 'global' will be
+  * merged with service-specific ones. The result will then be passed to
+  * VirtualRESTService::__construct() in the module.
   *
   * Example config for Parsoid:
   *
   * @since 1.25
   */
  $wgVirtualRestConfig = [
+       'paths' => [],
        'modules' => [],
        'global' => [
                # Timeout in seconds
@@@ -8355,7 -8361,7 +8374,7 @@@ $wgEventRelayerConfig = 
   * PHP version, and chosen database backend. The Wikimedia Foundation shares this data with
   * MediaWiki developers to help guide future development efforts.
   *
 - * For details about what data is sent, see: https://www.mediawiki.org/wiki/Pingback
 + * For details about what data is sent, see: https://www.mediawiki.org/wiki/Manual:$wgPingback
   *
   * @var bool
   * @since 1.28