Rename domain => localDomain in LBFactory for consistency
authorAaron Schulz <aschulz@wikimedia.org>
Fri, 16 Sep 2016 18:22:10 +0000 (11:22 -0700)
committerAaron Schulz <aschulz@wikimedia.org>
Sat, 17 Sep 2016 01:58:30 +0000 (18:58 -0700)
Change-Id: I2fb66f98dddb4acc38958a7b8beec002970d43f7

includes/db/loadbalancer/LBFactoryMW.php
includes/libs/rdbms/lbfactory/LBFactory.php

index 33c48a5..2fb48c7 100644 (file)
@@ -40,7 +40,7 @@ abstract class LBFactoryMW extends LBFactory implements DestructibleService {
                global $wgCommandLineMode;
 
                $defaults = [
-                       'domain' => wfWikiID(),
+                       'localDomain' => wfWikiID(),
                        'hostname' => wfHostname(),
                        'trxProfiler' => Profiler::instance()->getTransactionProfiler(),
                        'replLogger' => LoggerFactory::getInstance( 'DBReplication' ),
index 107a7e2..b6f3317 100644 (file)
@@ -50,7 +50,7 @@ abstract class LBFactory {
        protected $wanCache;
 
        /** @var string Local domain */
-       protected $domain;
+       protected $localDomain;
        /** @var string Local hostname of the app server */
        protected $hostname;
        /** @var mixed */
@@ -79,7 +79,7 @@ abstract class LBFactory {
         * @param array $conf
         */
        public function __construct( array $conf ) {
-               $this->domain = isset( $conf['domain'] ) ? $conf['domain'] : '';
+               $this->localDomain = isset( $conf['localDomain'] ) ? $conf['localDomain'] : '';
 
                if ( isset( $conf['readOnlyReason'] ) && is_string( $conf['readOnlyReason'] ) ) {
                        $this->readOnlyReason = $conf['readOnlyReason'];
@@ -608,7 +608,7 @@ abstract class LBFactory {
         */
        final protected function baseLoadBalancerParams() {
                return [
-                       'localDomain' => $this->domain,
+                       'localDomain' => $this->localDomain,
                        'readOnlyReason' => $this->readOnlyReason,
                        'srvCache' => $this->srvCache,
                        'wanCache' => $this->wanCache,
@@ -641,7 +641,7 @@ abstract class LBFactory {
         * @since 1.28
         */
        public function setDomainPrefix( $domain ) {
-               $this->domain = $domain;
+               $this->localDomain = $domain;
        }
 
        /**