Skip to content

Commit 04a05a2

Browse files
AaronSchulzKrinkle
authored andcommitted
rdbms: Rename "memCache" to "memStash" in LBFactory
This needs to be cross DC, so fix the name and comments. Also update the one MWLBFactory reference to it. Change-Id: I5ef10000276c300299fd1ece35ada0d78388bef7
1 parent 7bada04 commit 04a05a2

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

includes/db/MWLBFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ public static function applyDefaultConfig( array $lbConf, Config $mainConfig,
149149
}
150150
$cCache = ObjectCache::getLocalClusterInstance();
151151
if ( $cCache->getQoS( $cCache::ATTR_EMULATION ) > $cCache::QOS_EMULATION_SQL ) {
152-
$lbConf['memCache'] = $cCache;
152+
$lbConf['memStash'] = $cCache;
153153
}
154154
$wCache = MediaWikiServices::getInstance()->getMainWANObjectCache();
155155
if ( $wCache->getQoS( $wCache::ATTR_EMULATION ) > $wCache::QOS_EMULATION_SQL ) {

includes/libs/rdbms/lbfactory/ILBFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ interface ILBFactory {
4444
* - localDomain: A DatabaseDomain or domain ID string.
4545
* - readOnlyReason : Reason the master DB is read-only if so [optional]
4646
* - srvCache : BagOStuff object for server cache [optional]
47-
* - memCache : BagOStuff object for cluster memory cache [optional]
47+
* - memStash : BagOStuff object for cross-datacenter memory storage [optional]
4848
* - wanCache : WANObjectCache object [optional]
4949
* - hostname : The name of the current server [optional]
5050
* - cliMode: Whether the execution context is a CLI script. [optional]

includes/libs/rdbms/lbfactory/LBFactory.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ abstract class LBFactory implements ILBFactory {
5555
/** @var BagOStuff */
5656
protected $srvCache;
5757
/** @var BagOStuff */
58-
protected $memCache;
58+
protected $memStash;
5959
/** @var WANObjectCache */
6060
protected $wanCache;
6161

@@ -93,7 +93,7 @@ public function __construct( array $conf ) {
9393
}
9494

9595
$this->srvCache = isset( $conf['srvCache'] ) ? $conf['srvCache'] : new EmptyBagOStuff();
96-
$this->memCache = isset( $conf['memCache'] ) ? $conf['memCache'] : new EmptyBagOStuff();
96+
$this->memStash = isset( $conf['memStash'] ) ? $conf['memStash'] : new EmptyBagOStuff();
9797
$this->wanCache = isset( $conf['wanCache'] )
9898
? $conf['wanCache']
9999
: WANObjectCache::newEmpty();
@@ -435,7 +435,7 @@ protected function getChronologyProtector() {
435435
}
436436

437437
$this->chronProt = new ChronologyProtector(
438-
$this->memCache,
438+
$this->memStash,
439439
[
440440
'ip' => $this->requestInfo['IPAddress'],
441441
'agent' => $this->requestInfo['UserAgent'],

0 commit comments

Comments
 (0)