57 private $readOnlyMode;
60 private $statsdDataFactory;
66 private $globalIdGenerator;
83 $this->instances = [];
84 $this->options = $options;
85 $this->readOnlyMode = $readOnlyMode;
86 $this->statsdDataFactory = $statsdDataFactory;
87 $this->wanCache = $wanCache;
88 $this->globalIdGenerator = $globalIdGenerator;
98 if ( $domain === false ) {
99 $domain = WikiMap::getCurrentWikiDbDomain()->getId();
104 $wikiId = WikiMap::getWikiIdFromDbDomain( $domain );
106 !WikiMap::isCurrentWikiDbDomain( $domain ) &&
110 throw new LogicException(
"Domain '{$domain}' is not recognized." );
113 $localJobClasses = WikiMap::isCurrentWikiDbDomain( $domain )
117 if ( !isset( $this->instances[$domain] ) ) {
124 $this->statsdDataFactory,
126 $this->globalIdGenerator
130 return $this->instances[$domain];
if(!defined('MW_SETUP_CALLBACK'))
Handle enqueueing of background jobs.
A class containing constants representing the names of configuration variables.
const JobTypeConf
Name constant for the JobTypeConf setting, for use with Config::get()
const LocalDatabases
Name constant for the LocalDatabases setting, for use with Config::get()
const JobClasses
Name constant for the JobClasses setting, for use with Config::get()
const JobTypesExcludedFromDefaultQueue
Name constant for the JobTypesExcludedFromDefaultQueue setting, for use with Config::get()
Multi-datacenter aware caching interface.
MediaWiki adaptation of StatsdDataFactory that provides buffering functionality.