MediaWiki master
MessageCache.php
Go to the documentation of this file.
1<?php
6
7namespace MediaWiki\Language;
8
9use Exception;
10use InvalidArgumentException;
11use LogicException;
12use MediaWiki\Config\ServiceOptions;
13use MediaWiki\Content\Content;
14use MediaWiki\Deferred\DeferredUpdates;
15use MediaWiki\HookContainer\HookContainer;
16use MediaWiki\HookContainer\HookRunner;
17use MediaWiki\Logger\LoggerFactory;
18use MediaWiki\MainConfigNames;
19use MediaWiki\MediaWikiServices;
20use MediaWiki\Page\PageIdentity;
21use MediaWiki\Page\PageReference;
22use MediaWiki\Page\PageReferenceValue;
23use MediaWiki\Parser\ParserOutput;
24use MediaWiki\Revision\SlotRecord;
25use MediaWiki\StubObject\StubUserLang;
26use MediaWiki\Title\Title;
27use Psr\Log\LoggerAwareInterface;
28use Psr\Log\LoggerInterface;
29use RuntimeException;
30use Throwable;
31use Wikimedia\ObjectCache\BagOStuff;
32use Wikimedia\ObjectCache\EmptyBagOStuff;
33use Wikimedia\ObjectCache\MapCacheLRU;
34use Wikimedia\ObjectCache\WANObjectCache;
35use Wikimedia\Rdbms\IDBAccessObject;
36use Wikimedia\Rdbms\IExpression;
37use Wikimedia\Rdbms\IResultWrapper;
38use Wikimedia\Rdbms\LikeValue;
39use Wikimedia\RequestTimeout\TimeoutException;
40use Wikimedia\ScopedCallback;
41use Wikimedia\Timestamp\TimestampFormat as TS;
42
48class MessageCache implements LoggerAwareInterface {
52 public const CONSTRUCTOR_OPTIONS = [
58 ];
59
63 private const CACHE_VERSION = 2;
64
69 public const MAX_REQUEST_LANGUAGES = 10;
70
72 private const FOR_UPDATE = 1;
73
75 private const LOCK_WAIT_TIME = 15;
77 private const LOCK_TTL = 30;
78
82 private const WAN_TTL = BagOStuff::TTL_DAY;
83
85 private $logger;
86
92 private $cache;
93
99 private $systemMessageNames;
100
106 private $isCacheVolatile = [];
107
113 private $disabled;
114
116 private $maxEntrySize;
118 private $adaptive;
120 private $useXssLanguage;
122 private $rawHtmlMessages;
123
125 private $wanCache;
127 private $mainCache;
129 private $srvCache;
131 private $contLang;
133 private $contLangCode;
135 private $contLangConverter;
137 private $localisationCache;
139 private $languageNameUtils;
141 private $languageFallback;
143 private $hookRunner;
145 private $messageParser;
146
148 private $messageKeyOverrides;
149
165 public function __construct(
166 WANObjectCache $wanCache,
167 BagOStuff $mainCache,
168 BagOStuff $serverCache,
169 Language $contLang,
170 LanguageConverterFactory $langConverterFactory,
171 LoggerInterface $logger,
172 ServiceOptions $options,
173 LocalisationCache $localisationCache,
174 LanguageNameUtils $languageNameUtils,
175 LanguageFallback $languageFallback,
176 HookContainer $hookContainer,
177 MessageParser $messageParser
178 ) {
179 $this->wanCache = $wanCache;
180 $this->mainCache = $mainCache;
181 $this->srvCache = $serverCache;
182 $this->contLang = $contLang;
183 $this->contLangConverter = $langConverterFactory->getLanguageConverter( $contLang );
184 $this->contLangCode = $contLang->getCode();
185 $this->logger = $logger;
186 $this->localisationCache = $localisationCache;
187 $this->languageNameUtils = $languageNameUtils;
188 $this->languageFallback = $languageFallback;
189 $this->hookRunner = new HookRunner( $hookContainer );
190 $this->messageParser = $messageParser;
191
192 $this->cache = new MapCacheLRU( self::MAX_REQUEST_LANGUAGES );
193
194 $options->assertRequiredOptions( self::CONSTRUCTOR_OPTIONS );
195 if ( !$options->get( MainConfigNames::UseDatabaseMessages ) ) {
196 $this->disable( 'config' );
197 }
198 $this->maxEntrySize = $options->get( MainConfigNames::MaxMsgCacheEntrySize );
199 $this->adaptive = $options->get( MainConfigNames::AdaptiveMessageCache );
200 $this->useXssLanguage = $options->get( MainConfigNames::UseXssLanguage );
201 $this->rawHtmlMessages = $options->get( MainConfigNames::RawHtmlMessages );
202 }
203
204 public function setLogger( LoggerInterface $logger ): void {
205 $this->logger = $logger;
206 }
207
214 private function getLocalCache( $code ) {
215 $cacheKey = $this->srvCache->makeKey( __CLASS__, $code );
216
217 return $this->srvCache->get( $cacheKey );
218 }
219
226 private function saveToLocalCache( $code, $cache ) {
227 $cacheKey = $this->srvCache->makeKey( __CLASS__, $code );
228 $this->srvCache->set( $cacheKey, $cache );
229 }
230
251 private function load( string $code, $mode = null ) {
252 // Check if loading is done already
253 if ( $this->disabled ||
254 ( $mode !== self::FOR_UPDATE && $this->isLanguageLoaded( $code ) )
255 ) {
256 return true;
257 }
258
259 try {
260 return $this->loadUnguarded( $code, $mode );
261 } catch ( Throwable $e ) {
262 // Don't try to load again during the exception handler
263 $this->disable();
264 throw $e;
265 }
266 }
267
275 private function loadUnguarded( $code, $mode ) {
276 $success = false; // Keep track of success
277 $staleCache = false; // a cache array with expired data, or false if none has been loaded
278 $where = []; // Debug info, delayed to avoid spamming debug log too much
279
280 // A hash of the expected content is stored in a WAN cache key, providing a way
281 // to invalidate the local cache on every server whenever a message page changes.
282 [ $hash, $isCacheVolatile ] = $this->getValidationHash( $code );
283 $this->isCacheVolatile[$code] = $isCacheVolatile;
284 $isStaleDueToVolatility = false;
285
286 // Try the local cache and check against the main cache hash key...
287 $cache = $this->getLocalCache( $code );
288 if ( !$cache ) {
289 $where[] = 'local cache is empty';
290 } elseif ( !isset( $cache['HASH'] ) || $cache['HASH'] !== $hash ) {
291 $where[] = 'local cache has the wrong hash';
292 $staleCache = $cache;
293 } elseif ( $this->isCacheExpired( $cache ) ) {
294 $where[] = 'local cache is expired';
295 $staleCache = $cache;
296 } elseif ( $isCacheVolatile ) {
297 // Some recent message page changes might not show due to DB lag
298 $where[] = 'local cache validation key is expired/volatile';
299 $staleCache = $cache;
300 $isStaleDueToVolatility = true;
301 } else {
302 $where[] = 'got from local cache';
303 $this->cache->set( $code, $cache );
304 $success = true;
305 }
306
307 if ( !$success ) {
308 // Try the main cache, using a lock for regeneration...
309 $cacheKey = $this->mainCache->makeKey( 'messages', $code );
310 for ( $failedAttempts = 0; $failedAttempts <= 1; $failedAttempts++ ) {
311 if ( $isStaleDueToVolatility ) {
312 // While the main cache *might* be more up-to-date, we do not want
313 // the I/O strain of every application server fetching the key here during
314 // the volatility period. Either this thread wins the lock and regenerates
315 // the cache or the stale local cache value gets reused.
316 $where[] = 'global cache is presumed expired';
317 } else {
318 $cache = $this->mainCache->get( $cacheKey );
319 if ( !$cache ) {
320 $where[] = 'global cache is empty';
321 } elseif ( $this->isCacheExpired( $cache ) ) {
322 $where[] = 'global cache is expired';
323 $staleCache = $cache;
324 } elseif ( $isCacheVolatile ) {
325 // Some recent message page changes might not show due to DB lag
326 $where[] = 'global cache is expired/volatile';
327 $staleCache = $cache;
328 } else {
329 $where[] = 'got from global cache';
330 $this->cache->set( $code, $cache );
331 $this->saveToCaches( $cache, 'local-only', $code );
332 $success = true;
333 break;
334 }
335 }
336
337 // We need to call loadFromDB(). Limit the concurrency to one thread.
338 // This prevents the site from going down when the cache expires.
339 // Note that the DB slam protection lock here is non-blocking.
340 $loadStatus = $this->loadFromDBWithMainLock( $code, $where, $mode );
341 if ( $loadStatus === true ) {
342 $success = true;
343 break;
344 } elseif ( $staleCache ) {
345 // Use the stale cache while some other thread constructs the new one
346 $where[] = 'using stale cache';
347 $this->cache->set( $code, $staleCache );
348 $success = true;
349 break;
350 } elseif ( $failedAttempts > 0 ) {
351 $where[] = 'failed to find cache after waiting';
352 // Already blocked once, so avoid another lock/unlock cycle.
353 // This case will typically be hit if memcached is down, or if
354 // loadFromDB() takes longer than LOCK_WAIT.
355 break;
356 } elseif ( $loadStatus === 'cant-acquire' ) {
357 // Wait for the other thread to finish, then retry. Normally,
358 // the memcached get() will then yield the other thread's result.
359 $where[] = 'waiting for other thread to complete';
360 [ , $ioError ] = $this->getReentrantScopedLock( $code );
361 if ( $ioError ) {
362 $where[] = 'failed waiting';
363 // Call loadFromDB() with concurrency limited to one thread per server.
364 // It should be rare for all servers to lack even a stale local cache.
365 $success = $this->loadFromDBWithLocalLock( $code, $where, $mode );
366 break;
367 }
368 } else {
369 // Disable cache; $loadStatus is 'disabled'
370 break;
371 }
372 }
373 }
374
375 if ( !$success ) {
376 $where[] = 'loading FAILED - cache is disabled';
377 $this->disable();
378 $this->cache->set( $code, [] );
379 $this->logger->error( __METHOD__ . ": Failed to load $code" );
380 // This used to throw an exception, but that led to nasty side effects like
381 // the whole wiki being instantly down if the memcached server died
382 }
383
384 if ( !$this->isLanguageLoaded( $code ) ) {
385 throw new LogicException( "Process cache for '$code' should be set by now." );
386 }
387
388 $info = implode( ', ', $where );
389 $this->logger->debug( __METHOD__ . ": Loading $code... $info" );
390
391 return $success;
392 }
393
400 private function loadFromDBWithMainLock( $code, array &$where, $mode = null ) {
401 // If cache updates on all levels fail, give up on message overrides.
402 // This is to avoid easy site outages; see $saveSuccess comments below.
403 $statusKey = $this->mainCache->makeKey( 'messages', $code, 'status' );
404 $status = $this->mainCache->get( $statusKey );
405 if ( $status === 'error' ) {
406 $where[] = "could not load; method is still globally disabled";
407 return 'disabled';
408 }
409
410 // Now let's regenerate
411 $where[] = 'loading from DB';
412
413 // Lock the cache to prevent conflicting writes.
414 // This lock is non-blocking so stale cache can quickly be used.
415 // Note that load() will call a blocking getReentrantScopedLock()
416 // after this if it really needs to wait for any current thread.
417 [ $scopedLock ] = $this->getReentrantScopedLock( $code, 0 );
418 if ( !$scopedLock ) {
419 $where[] = 'could not acquire main lock';
420 return 'cant-acquire';
421 }
422
423 $cache = $this->loadFromDB( $code, $mode );
424 $this->cache->set( $code, $cache );
425 $saveSuccess = $this->saveToCaches( $cache, 'all', $code );
426
427 if ( !$saveSuccess ) {
437 if ( $this->srvCache instanceof EmptyBagOStuff ) {
438 $this->mainCache->set( $statusKey, 'error', 60 * 5 );
439 $where[] = 'could not save cache, disabled globally for 5 minutes';
440 } else {
441 $where[] = "could not save global cache";
442 }
443 }
444
445 return true;
446 }
447
454 private function loadFromDBWithLocalLock( $code, array &$where, $mode = null ) {
455 $success = false;
456 $where[] = 'loading from DB using local lock';
457
458 $scopedLock = $this->srvCache->getScopedLock(
459 $this->srvCache->makeKey( 'messages', $code ),
460 self::LOCK_WAIT_TIME,
461 self::LOCK_TTL,
462 __METHOD__
463 );
464 if ( $scopedLock ) {
465 $cache = $this->loadFromDB( $code, $mode );
466 $this->cache->set( $code, $cache );
467 $this->saveToCaches( $cache, 'local-only', $code );
468 $success = true;
469 }
470
471 return $success;
472 }
473
483 private function loadFromDB( $code, $mode = null ) {
484 $icp = MediaWikiServices::getInstance()->getConnectionProvider();
485
486 $dbr = ( $mode === self::FOR_UPDATE ) ? $icp->getPrimaryDatabase() : $icp->getReplicaDatabase();
487
488 $cache = [];
489
490 $mostUsed = []; // list of "<cased message key>/<code>"
491 if ( $this->adaptive && $code !== $this->contLangCode ) {
492 if ( !$this->cache->has( $this->contLangCode ) ) {
493 $this->load( $this->contLangCode );
494 }
495 $mostUsed = array_keys( $this->cache->get( $this->contLangCode ) );
496 foreach ( $mostUsed as $key => $value ) {
497 $mostUsed[$key] = "$value/$code";
498 }
499 }
500
501 // Common conditions
502 $conds = [
503 // Treat redirects as not existing (T376398)
504 'page_is_redirect' => 0,
505 'page_namespace' => NS_MEDIAWIKI,
506 ];
507 if ( count( $mostUsed ) ) {
508 $conds['page_title'] = $mostUsed;
509 } elseif ( $code !== $this->contLangCode ) {
510 $conds[] = $dbr->expr(
511 'page_title',
512 IExpression::LIKE,
513 new LikeValue( $dbr->anyString(), '/', $code )
514 );
515 } else {
516 // Effectively disallows use of '/' character in NS_MEDIAWIKI for uses
517 // other than language code.
518 $conds[] = $dbr->expr(
519 'page_title',
520 IExpression::NOT_LIKE,
521 new LikeValue( $dbr->anyString(), '/', $dbr->anyString() )
522 );
523 }
524
525 // Set the stubs for oversized software-defined messages in the main cache map
526 $res = $dbr->newSelectQueryBuilder()
527 ->select( [ 'page_title', 'page_latest' ] )
528 ->from( 'page' )
529 ->where( $conds )
530 ->andWhere( $dbr->expr( 'page_len', '>', intval( $this->maxEntrySize ) ) )
531 ->caller( __METHOD__ . "($code)-big" )->fetchResultSet();
532 foreach ( $res as $row ) {
533 // Include entries/stubs for all keys in $mostUsed in adaptive mode
534 if ( $this->adaptive || $this->isMainCacheable( $row->page_title ) ) {
535 $cache[$row->page_title] = '!TOO BIG';
536 }
537 // At least include revision ID so page changes are reflected in the hash
538 $cache['EXCESSIVE'][$row->page_title] = $row->page_latest;
539 }
540
541 // RevisionStore cannot be injected as it would break the installer since
542 // it instantiates MessageCache before the DB.
543 $revisionStore = MediaWikiServices::getInstance()->getRevisionStore();
544 // Set the text for small software-defined messages in the main cache map
545 $revQuery = $revisionStore->getQueryInfo( [ 'page' ] );
546
547 // T231196: MySQL/MariaDB (10.1.37) can sometimes irrationally decide that querying `actor` then
548 // `revision` then `page` is somehow better than starting with `page`. Tell it not to reorder the
549 // query (and also reorder it ourselves because as generated by RevisionStore it'll have
550 // `revision` first rather than `page`).
551 $revQuery['joins']['revision'] = $revQuery['joins']['page'];
552 unset( $revQuery['joins']['page'] );
553 // It isn't actually necessary to reorder $revQuery['tables'] as Database does the right thing
554 // when join conditions are given for all joins, but Gergő is wary of relying on that so pull
555 // `page` to the start.
556 $revQuery['tables'] = array_merge(
557 [ 'page' ],
558 array_diff( $revQuery['tables'], [ 'page' ] )
559 );
560
561 $res = $dbr->newSelectQueryBuilder()
562 ->queryInfo( $revQuery )
563 ->where( $conds )
564 ->andWhere( [
565 $dbr->expr( 'page_len', '<=', intval( $this->maxEntrySize ) ),
566 'page_latest = rev_id' // get the latest revision only
567 ] )
568 ->caller( __METHOD__ . "($code)-small" )
569 ->straightJoinOption()
570 ->fetchResultSet();
571
572 // Don't load content from uncacheable rows (T313004)
573 [ $cacheableRows, $uncacheableRows ] = $this->separateCacheableRows( $res );
574 $result = $revisionStore->newRevisionsFromBatch( $cacheableRows, [
575 'slots' => [ SlotRecord::MAIN ],
576 'content' => true
577 ] );
578 $revisions = $result->isOK() ? $result->getValue() : [];
579
580 foreach ( $cacheableRows as $row ) {
581 try {
582 $rev = $revisions[$row->rev_id] ?? null;
583 $content = $rev ? $rev->getContent( SlotRecord::MAIN ) : null;
584 $text = $this->getMessageTextFromContent( $content );
585 } catch ( TimeoutException $e ) {
586 throw $e;
587 } catch ( Exception ) {
588 $text = false;
589 }
590
591 if ( !is_string( $text ) ) {
592 $entry = '!ERROR';
593 $this->logger->error(
594 __METHOD__
595 . ": failed to load message page text for {$row->page_title} ($code)"
596 );
597 } else {
598 $entry = ' ' . $text;
599 }
600 $cache[$row->page_title] = $entry;
601 }
602
603 foreach ( $uncacheableRows as $row ) {
604 // T193271: The cache object gets too big and slow to generate.
605 // At least include revision ID, so that page changes are reflected in the hash.
606 $cache['EXCESSIVE'][$row->page_title] = $row->page_latest;
607 }
608
609 $cache['VERSION'] = self::CACHE_VERSION;
610 ksort( $cache );
611
612 // Hash for validating local cache (APC). No need to take into account
613 // messages larger than $wgMaxMsgCacheEntrySize, since those are only
614 // stored and fetched from memcache.
615 $cache['HASH'] = md5( serialize( $cache ) );
616 $cache['EXPIRY'] = wfTimestamp( TS::MW, time() + self::WAN_TTL );
617 unset( $cache['EXCESSIVE'] ); // only needed for hash
618
619 return $cache;
620 }
621
628 private function isLanguageLoaded( $lang ) {
629 // It is important that this only returns true if the cache was fully
630 // populated by load(), so that callers can assume all cache keys exist.
631 // It is possible for $this->cache to be only partially populated through
632 // methods like MessageCache::replace(), which must not make this method
633 // return true (T208897). And this method must cease to return true
634 // if the language was evicted by MapCacheLRU (T230690).
635 return $this->cache->hasField( $lang, 'VERSION' );
636 }
637
649 private function isMainCacheable( $name, $code = null ) {
650 // Convert the first letter to lowercase, and strip /code suffix
651 $name = $this->contLang->lcfirst( $name );
652 // Include common conversion table pages. This also avoids problems with
653 // Installer::parse() bailing out due to disallowed DB queries (T207979).
654 if ( str_starts_with( $name, 'conversiontable/' ) ) {
655 return true;
656 }
657 $msg = preg_replace( '/\/[a-z0-9-]{2,}$/', '', $name );
658
659 if ( $code === null ) {
660 // Bulk load
661 if ( $this->systemMessageNames === null ) {
662 $this->systemMessageNames = array_fill_keys(
663 $this->localisationCache->getSubitemList( $this->contLangCode, 'messages' ),
664 true );
665 }
666 return isset( $this->systemMessageNames[$msg] );
667 } else {
668 // Use individual subitem
669 return $this->localisationCache->getSubitem( $code, 'messages', $msg ) !== null;
670 }
671 }
672
680 private function separateCacheableRows( $res ) {
681 if ( $this->adaptive ) {
682 // Include entries/stubs for all keys in $mostUsed in adaptive mode
683 return [ $res, [] ];
684 }
685 $cacheableRows = [];
686 $uncacheableRows = [];
687 foreach ( $res as $row ) {
688 if ( $this->isMainCacheable( $row->page_title ) ) {
689 $cacheableRows[] = $row;
690 } else {
691 $uncacheableRows[] = $row;
692 }
693 }
694 return [ $cacheableRows, $uncacheableRows ];
695 }
696
703 public function replace( $title, $text ) {
704 if ( $this->disabled ) {
705 return;
706 }
707
708 [ $msg, $code ] = $this->figureMessage( $title );
709 if ( str_contains( $title, '/' ) && $code === $this->contLangCode ) {
710 // Content language overrides do not use the /<code> suffix
711 return;
712 }
713
714 // (a) Update the process cache with the new message text
715 if ( $text === false ) {
716 // Page deleted
717 $this->cache->setField( $code, $title, '!NONEXISTENT' );
718 } else {
719 // Ignore $wgMaxMsgCacheEntrySize so the process cache is up-to-date
720 $this->cache->setField( $code, $title, ' ' . $text );
721 }
722
723 // (b) Update the shared caches in a deferred update with a fresh DB snapshot
724 DeferredUpdates::addUpdate(
725 new MessageCacheUpdate( $code, $title, $msg ),
726 DeferredUpdates::PRESEND
727 );
728 }
729
735 public function refreshAndReplaceInternal( string $code, array $replacements ) {
736 // Allow one caller at a time to avoid race conditions
737 [ $scopedLock ] = $this->getReentrantScopedLock( $code );
738 if ( !$scopedLock ) {
739 foreach ( $replacements as [ $title ] ) {
740 $this->logger->error(
741 __METHOD__ . ': could not acquire lock to update {title} ({code})',
742 [ 'title' => $title, 'code' => $code ] );
743 }
744
745 return;
746 }
747
748 // Load the existing cache to update it in the local DC cache.
749 // The other DCs will see a hash mismatch.
750 if ( $this->load( $code, self::FOR_UPDATE ) ) {
751 $cache = $this->cache->get( $code );
752 } else {
753 // Err? Fall back to loading from the database.
754 $cache = $this->loadFromDB( $code, self::FOR_UPDATE );
755 }
756 // Check if individual cache keys should exist and update cache accordingly
757 $newTextByTitle = []; // map of (title => content)
758 $newBigTitles = []; // map of (title => latest revision ID), like EXCESSIVE in loadFromDB()
759 // Can not inject the WikiPageFactory as it would break the installer since
760 // it instantiates MessageCache before the DB.
761 $wikiPageFactory = MediaWikiServices::getInstance()->getWikiPageFactory();
762 foreach ( $replacements as [ $title ] ) {
763 $page = $wikiPageFactory->newFromTitle( Title::makeTitle( NS_MEDIAWIKI, $title ) );
764 $page->loadPageData( IDBAccessObject::READ_LATEST );
765 $text = $this->getMessageTextFromContent( $page->getContent() );
766 // Remember the text for the blob store update later on
767 $newTextByTitle[$title] = $text ?? '';
768 // Note that if $text is false, then $cache should have a !NONEXISTENT entry
769 if ( !is_string( $text ) ) {
770 $cache[$title] = '!NONEXISTENT';
771 } elseif ( strlen( $text ) > $this->maxEntrySize ) {
772 $cache[$title] = '!TOO BIG';
773 $newBigTitles[$title] = $page->getLatest();
774 } else {
775 $cache[$title] = ' ' . $text;
776 }
777 }
778 // Update HASH for the new key. Incorporates various administrative keys,
779 // including the old HASH (and thereby the EXCESSIVE value from loadFromDB()
780 // and previous replace() calls), but that doesn't really matter since we
781 // only ever compare it for equality with a copy saved by saveToCaches().
782 $cache['HASH'] = md5( serialize( $cache + [ 'EXCESSIVE' => $newBigTitles ] ) );
783 // Update the too-big WAN cache entries now that we have the new HASH
784 foreach ( $newBigTitles as $title => $id ) {
785 // Match logic of loadCachedMessagePageEntry()
786 $this->wanCache->set(
787 $this->bigMessageCacheKey( $cache['HASH'], $title ),
788 ' ' . $newTextByTitle[$title],
789 self::WAN_TTL
790 );
791 }
792 // Mark this cache as definitely being "latest" (non-volatile) so
793 // load() calls do not try to refresh the cache with replica DB data
794 $cache['LATEST'] = time();
795 // Update the process cache
796 $this->cache->set( $code, $cache );
797 // Pre-emptively update the local datacenter cache so things like edit filter and
798 // prevented changes are reflected immediately; these often use MediaWiki: pages.
799 // The datacenter handling replace() calls should be the same one handling edits
800 // as they require HTTP POST.
801 $this->saveToCaches( $cache, 'all', $code );
802 // Release the lock now that the cache is saved
803 ScopedCallback::consume( $scopedLock );
804
805 // Relay the purge. Touching this check key expires cache contents
806 // and local cache (APC) validation hash across all datacenters.
807 $this->wanCache->touchCheckKey( $this->getCheckKey( $code ) );
808
809 // Purge the messages in the message blob store and fire any hook handlers
810 $blobStore = MediaWikiServices::getInstance()->getResourceLoader()->getMessageBlobStore();
811 foreach ( $replacements as [ $title, $msg ] ) {
812 $blobStore->updateMessage( $this->contLang->lcfirst( $msg ) );
813 $this->hookRunner->onMessageCacheReplace( $title, $newTextByTitle[$title] );
814 }
815 }
816
823 private function isCacheExpired( $cache ) {
824 return !isset( $cache['VERSION'] ) ||
825 !isset( $cache['EXPIRY'] ) ||
826 $cache['VERSION'] !== self::CACHE_VERSION ||
827 $cache['EXPIRY'] <= wfTimestampNow();
828 }
829
840 private function saveToCaches( array $cache, $dest, $code = false ) {
841 if ( $dest === 'all' ) {
842 $cacheKey = $this->mainCache->makeKey( 'messages', $code );
843 $success = $this->mainCache->set( $cacheKey, $cache );
844 $this->setValidationHash( $code, $cache );
845 } else {
846 $success = true;
847 }
848
849 $this->saveToLocalCache( $code, $cache );
850
851 return $success;
852 }
853
860 private function getValidationHash( $code ) {
861 $curTTL = null;
862 $value = $this->wanCache->get(
863 $this->wanCache->makeKey( 'messages', $code, 'hash', 'v1' ),
864 $curTTL,
865 [ $this->getCheckKey( $code ) ]
866 );
867
868 if ( $value ) {
869 $hash = $value['hash'];
870 if ( ( time() - $value['latest'] ) < WANObjectCache::TTL_MINUTE ) {
871 // Cache was recently updated via replace() and should be up-to-date.
872 // That method is only called in the primary datacenter and uses FOR_UPDATE.
873 $isCacheVolatile = false;
874 } else {
875 // See if the "check" key was bumped after the hash was generated
876 $isCacheVolatile = ( $curTTL < 0 );
877 }
878 } else {
879 // No hash found at all; cache must regenerate to be safe
880 $hash = false;
881 $isCacheVolatile = true;
882 }
883
884 return [ $hash, $isCacheVolatile ];
885 }
886
897 private function setValidationHash( $code, array $cache ) {
898 $this->wanCache->set(
899 $this->wanCache->makeKey( 'messages', $code, 'hash', 'v1' ),
900 [
901 'hash' => $cache['HASH'],
902 'latest' => $cache['LATEST'] ?? 0
903 ],
904 WANObjectCache::TTL_INDEFINITE
905 );
906 }
907
914 private function getReentrantScopedLock( $code, $timeout = self::LOCK_WAIT_TIME ) {
915 $key = $this->mainCache->makeKey( 'messages', $code );
916
917 $watchPoint = $this->mainCache->watchErrors();
918 $scopedLock = $this->mainCache->getScopedLock(
919 $key,
920 $timeout,
921 self::LOCK_TTL,
922 __METHOD__
923 );
924 $error = ( !$scopedLock && $this->mainCache->getLastError( $watchPoint ) );
925
926 return [ $scopedLock, $error ];
927 }
928
935 public function normalizeKey( string $key ): string {
936 if ( $key === '' ) {
937 return '';
938 }
939 $lckey = strtr( $key, ' ', '_' );
940 if ( ord( $lckey[0] ) < 128 ) {
941 $lckey[0] = strtolower( $lckey[0] );
942 } else {
943 $lckey = $this->contLang->lcfirst( $lckey );
944 }
945
946 return $lckey;
947 }
948
979 public function get( $key, $useDB = true, ?string $langCode = null, $info = null ) {
980 if ( is_int( $key ) ) {
981 // Fix numerical strings that somehow become ints on their way here
982 $key = (string)$key;
983 } elseif ( !is_string( $key ) ) {
984 throw new InvalidArgumentException( 'Message key must be a string' );
985 } elseif ( $key === '' ) {
986 // Shortcut: the empty key is always missing
987 return false;
988 }
989
990 // Ignore legacy $usedKey parameter
991 if ( $info && !( $info instanceof MessageInfo ) ) {
992 $info = null;
993 }
994
995 if ( $langCode === null ) {
996 $langCode = $this->contLangCode;
997 } elseif ( !$this->languageNameUtils->isValidCode( $langCode ) ) {
998 // $langCode is not a valid language code; use content language code.
999 $this->logger->debug( 'Invalid language code passed to ' . __METHOD__ .
1000 ', falling back to content language.' );
1001 $langCode = $this->contLangCode;
1002 }
1003
1004 // Normalise title-case input (with some inlining)
1005 $lckey = $this->normalizeKey( $key );
1006
1007 // Initialize the overrides here to prevent calling the hook too early.
1008 if ( $this->messageKeyOverrides === null ) {
1009 $this->messageKeyOverrides = [];
1010 $this->hookRunner->onMessageCacheFetchOverrides( $this->messageKeyOverrides );
1011 }
1012
1013 if ( isset( $this->messageKeyOverrides[$lckey] ) ) {
1014 $override = $this->messageKeyOverrides[$lckey];
1015
1016 // Strings are deliberately interpreted as message keys,
1017 // to prevent ambiguity between message keys and functions.
1018 if ( is_string( $override ) ) {
1019 $lckey = $override;
1020 } else {
1021 $lckey = $override( $lckey, $this );
1022 }
1023 }
1024
1025 $this->hookRunner->onMessageCache__get( $lckey );
1026
1027 if ( $info ) {
1028 $info->usedKey = $lckey;
1029 }
1030
1031 // Loop through each language in the fallback list until we find something useful
1032 $message = $this->getMessageFromFallbackChain(
1033 $langCode,
1034 $lckey,
1035 !$this->disabled && $useDB,
1036 $info
1037 );
1038
1039 // If we still have no message, maybe the key was in fact a full key, so try that
1040 if ( $message === false ) {
1041 $parts = explode( '/', $lckey );
1042 // We may get calls for things that are HTTP URLs from the sidebar
1043 // Let's not load nonexistent languages for those
1044 // They usually have more than one slash.
1045 if ( count( $parts ) === 2 && $parts[1] !== '' ) {
1046 $message = $this->localisationCache->getSubitem( $parts[1], 'messages', $parts[0] ) ?? false;
1047 if ( $message !== false && $info ) {
1048 $info->usedKey = $parts[0];
1049 $info->langCode = $parts[1];
1050 }
1051 }
1052 }
1053
1054 // Post-processing if the message exists
1055 if ( $message !== false ) {
1056 // Fix whitespace
1057 $message = str_replace(
1058 [
1059 // Fix for trailing whitespace, removed by textarea
1060 '&#32;',
1061 // Fix for NBSP, converted to space by firefox
1062 '&nbsp;',
1063 '&#160;',
1064 '&shy;'
1065 ],
1066 [
1067 ' ',
1068 "\u{00A0}",
1069 "\u{00A0}",
1070 "\u{00AD}"
1071 ],
1072 $message
1073 );
1074 }
1075
1076 return $message;
1077 }
1078
1090 private function getMessageFromFallbackChain( $code, $lckey, $useDB, $info ) {
1091 $alreadyTried = [];
1092
1093 // First try the requested language.
1094 $message = $this->getMessageForLang( $code, $lckey, $useDB, $alreadyTried, $info );
1095 if ( $message !== false ) {
1096 return $message;
1097 }
1098
1099 // Now try checking the site language.
1100 $message = $this->getMessageForLang( $this->contLangCode, $lckey, $useDB, $alreadyTried, $info );
1101 return $message;
1102 }
1103
1115 private function getMessageForLang( $langCode, $lckey, $useDB, &$alreadyTried, $info ) {
1116 // Try checking the database for the requested language
1117 if ( $useDB ) {
1118 $uckey = $this->contLang->ucfirst( $lckey );
1119
1120 if ( !isset( $alreadyTried[$langCode] ) ) {
1121 $message = $this->getMsgFromNamespace(
1122 $this->getMessagePageName( $langCode, $uckey ),
1123 $langCode
1124 );
1125 if ( $message !== false ) {
1126 if ( $info ) {
1127 $info->langCode = $langCode;
1128 }
1129 return $message;
1130 }
1131 $alreadyTried[$langCode] = true;
1132 }
1133 } else {
1134 $uckey = null;
1135 }
1136
1137 // Return a special value handled in Message::format() to display the message key
1138 // (and fallback keys) and the parameters passed to the message.
1139 // TODO: Move to a better place.
1140 if ( $langCode === 'qqx' ) {
1141 return '($*)';
1142 } elseif (
1143 $langCode === 'x-xss' &&
1144 $this->useXssLanguage &&
1145 !in_array( $lckey, $this->rawHtmlMessages, true )
1146 ) {
1147 $lcKeyForAlert = str_replace( [ '"', "'" ], '_', $lckey );
1148 $xssViaInnerHtml = "<img src=\"\" onerror='alert(\"$lcKeyForAlert\")'/>";
1149 $xssViaAttribute = '">' . $xssViaInnerHtml . '<x y="';
1150 return $xssViaInnerHtml . $xssViaAttribute . '($*)';
1151 }
1152
1153 // Check the localisation cache
1154 [ $defaultMessage, $messageSource ] =
1155 $this->localisationCache->getSubitemWithSource( $langCode, 'messages', $lckey );
1156 if ( $messageSource === $langCode ) {
1157 if ( $info ) {
1158 $info->langCode = $langCode;
1159 }
1160 return $defaultMessage;
1161 }
1162
1163 // Try checking the database for all of the fallback languages
1164 if ( $useDB ) {
1165 $fallbackChain = $this->languageFallback->getAll( $langCode );
1166
1167 foreach ( $fallbackChain as $code ) {
1168 if ( isset( $alreadyTried[$code] ) ) {
1169 continue;
1170 }
1171
1172 $message = $this->getMsgFromNamespace(
1173 // @phan-suppress-next-line PhanTypeMismatchArgumentNullable uckey is set when used
1174 $this->getMessagePageName( $code, $uckey ), $code );
1175
1176 if ( $message !== false ) {
1177 if ( $info ) {
1178 $info->langCode = $code;
1179 }
1180 return $message;
1181 }
1182 $alreadyTried[$code] = true;
1183
1184 // Reached the source language of the default message. Don't look for DB overrides
1185 // further back in the fallback chain. (T229992)
1186 if ( $code === $messageSource ) {
1187 if ( $info ) {
1188 $info->langCode = $code;
1189 }
1190 return $defaultMessage;
1191 }
1192 }
1193 }
1194
1195 if ( $defaultMessage !== null && $info ) {
1196 $info->langCode = $messageSource;
1197 }
1198 return $defaultMessage ?? false;
1199 }
1200
1208 private function getMessagePageName( $langCode, $uckey ) {
1209 if ( $langCode === $this->contLangCode ) {
1210 // Messages created in the content language will not have the /lang extension
1211 return $uckey;
1212 } else {
1213 return "$uckey/$langCode";
1214 }
1215 }
1216
1229 public function getMsgFromNamespace( $title, $code ) {
1230 // Load all MediaWiki page definitions into cache. Note that individual keys
1231 // already loaded into the cache during this request remain in the cache, which
1232 // includes the value of hook-defined messages.
1233 $this->load( $code );
1234
1235 $entry = $this->cache->getField( $code, $title );
1236
1237 if ( $entry !== null ) {
1238 // Message page exists as an override of a software messages
1239 if ( str_starts_with( $entry, ' ' ) ) {
1240 // The message exists and is not '!TOO BIG' or '!ERROR'
1241 return substr( $entry, 1 );
1242 } elseif ( $entry === '!NONEXISTENT' ) {
1243 // The text might be '-' or missing due to some data loss
1244 return false;
1245 }
1246 // Load the message page, utilizing the individual message cache.
1247 // If the page does not exist, there will be no hook handler fallbacks.
1248 $entry = $this->loadCachedMessagePageEntry(
1249 $title,
1250 $code,
1251 $this->cache->getField( $code, 'HASH' )
1252 );
1253 } else {
1254 // Message page either does not exist or does not override a software message
1255 if ( !$this->isMainCacheable( $title, $code ) ) {
1256 // Message page does not override any software-defined message. A custom
1257 // message might be defined to have content or settings specific to the wiki.
1258 // Load the message page, utilizing the individual message cache as needed.
1259 $entry = $this->loadCachedMessagePageEntry(
1260 $title,
1261 $code,
1262 $this->cache->getField( $code, 'HASH' )
1263 );
1264 }
1265 if ( $entry === null || !str_starts_with( $entry, ' ' ) ) {
1266 // Message does not have a MediaWiki page definition; try hook handlers
1267 $message = false;
1268 // @phan-suppress-next-line PhanTypeMismatchArgument Type mismatch on pass-by-ref args
1269 $this->hookRunner->onMessagesPreLoad( $title, $message, $code );
1270 if ( $message !== false ) {
1271 $this->cache->setField( $code, $title, ' ' . $message );
1272 } else {
1273 $this->cache->setField( $code, $title, '!NONEXISTENT' );
1274 }
1275
1276 return $message;
1277 }
1278 }
1279
1280 if ( $entry !== false && str_starts_with( $entry, ' ' ) ) {
1281 if ( $this->isCacheVolatile[$code] ) {
1282 // Make sure that individual keys respect the WAN cache holdoff period too
1283 $this->logger->debug(
1284 __METHOD__ . ': loading volatile key \'{titleKey}\'',
1285 [ 'titleKey' => $title, 'code' => $code ] );
1286 } else {
1287 $this->cache->setField( $code, $title, $entry );
1288 }
1289 // The message exists, so make sure a string is returned
1290 return substr( $entry, 1 );
1291 }
1292
1293 $this->cache->setField( $code, $title, '!NONEXISTENT' );
1294
1295 return false;
1296 }
1297
1304 private function loadCachedMessagePageEntry( $dbKey, $code, $hash ) {
1305 $fname = __METHOD__;
1306 return $this->srvCache->getWithSetCallback(
1307 $this->srvCache->makeKey( 'messages-big', $hash, $dbKey ),
1308 BagOStuff::TTL_HOUR,
1309 function () use ( $code, $dbKey, $hash, $fname ) {
1310 return $this->wanCache->getWithSetCallback(
1311 $this->bigMessageCacheKey( $hash, $dbKey ),
1312 self::WAN_TTL,
1313 function ( $oldValue, &$ttl ) use ( $dbKey, $code, $fname ) {
1314 // Try loading the message from the database
1315 // Use newKnownCurrent() to avoid querying revision/user tables
1316 $title = Title::makeTitle( NS_MEDIAWIKI, $dbKey );
1317 // Injecting RevisionStore breaks installer since it
1318 // instantiates MessageCache before DB.
1319 $revision = MediaWikiServices::getInstance()
1320 ->getRevisionLookup()
1321 ->getKnownLatestRevision( $title );
1322 if ( !$revision ) {
1323 // The wiki doesn't have a local override page. Cache absence with normal TTL.
1324 // When overrides are created, self::replace() takes care of the cache.
1325 return '!NONEXISTENT';
1326 }
1327 $content = $revision->getContent( SlotRecord::MAIN );
1328 if ( $content ) {
1329 $message = $this->getMessageTextFromContent( $content );
1330 } else {
1331 $this->logger->warning(
1332 $fname . ': failed to load page text for \'{titleKey}\'',
1333 [ 'titleKey' => $dbKey, 'code' => $code ]
1334 );
1335 $message = null;
1336 }
1337
1338 if ( !is_string( $message ) ) {
1339 // Revision failed to load Content, or Content is incompatible with wikitext.
1340 // Possibly a temporary loading failure.
1341 $ttl = 5;
1342
1343 return '!NONEXISTENT';
1344 }
1345
1346 return ' ' . $message;
1347 }
1348 );
1349 }
1350 );
1351 }
1352
1362 public function transform( $message, $interface = false, $language = null, ?PageReference $page = null ) {
1363 return $this->messageParser->transform(
1364 $message, $interface, $language, $page );
1365 }
1366
1381 string $text, PageReference $contextPage,
1382 bool $linestart = true,
1383 bool $interface = false,
1384 $language = null
1385 ): ParserOutput {
1386 return $this->messageParser->parse(
1387 $text, $contextPage, $linestart, $interface, $language );
1388 }
1389
1400 public function parse( $text, ?PageReference $page = null,
1401 $linestart = true, $interface = false, $language = null
1402 ) {
1403 // phpcs:ignore MediaWiki.Usage.DeprecatedGlobalVariables.Deprecated$wgTitle
1404 global $wgTitle;
1405 if ( !$page ) {
1406 $logger = LoggerFactory::getInstance( 'GlobalTitleFail' );
1407 $logger->info(
1408 __METHOD__ . ' called with no title set.',
1409 [ 'exception' => new RuntimeException ]
1410 );
1411 $page = $wgTitle;
1412 }
1413 // Sometimes $wgTitle isn't set either...
1414 if ( !$page ) {
1415 // It's not uncommon having a null $wgTitle in scripts. See r80898
1416 // Create a ghost title in such case
1417 $page = PageReferenceValue::localReference(
1418 NS_SPECIAL,
1419 'Badtitle/title not set in ' . __METHOD__
1420 );
1421 }
1422
1423 return $this->messageParser->parseWithoutPostprocessing(
1424 $text, $page, $linestart, $interface, $language );
1425 }
1426
1433 public function disable( $logReason = '' ) {
1434 if ( $logReason !== '' ) {
1435 $this->logger->debug( "disabling MessageCache: $logReason" );
1436 }
1437 $this->disabled = true;
1438 }
1439
1443 public function enable() {
1444 $this->logger->debug( "re-enabling MessageCache" );
1445 $this->disabled = false;
1446 }
1447
1461 public function isDisabled() {
1462 return $this->disabled;
1463 }
1464
1470 public function clear() {
1471 $langs = $this->languageNameUtils->getLanguageNames();
1472 foreach ( $langs as $code => $_ ) {
1473 $this->wanCache->touchCheckKey( $this->getCheckKey( $code ) );
1474 }
1475 $this->cache->clear();
1476 }
1477
1485 public function figureMessage( $key ) {
1486 $pieces = explode( '/', $key );
1487 if ( count( $pieces ) < 2 ) {
1488 return [ $key, $this->contLangCode ];
1489 }
1490
1491 $lang = array_pop( $pieces );
1492 if ( !$this->languageNameUtils->getLanguageName(
1493 $lang,
1496 ) ) {
1497 return [ $key, $this->contLangCode ];
1498 }
1499
1500 $message = implode( '/', $pieces );
1501
1502 return [ $message, $lang ];
1503 }
1504
1514 public function getAllMessageKeys( $code ) {
1515 $this->load( $code );
1516 if ( !$this->cache->has( $code ) ) {
1517 // Apparently load() failed
1518 return null;
1519 }
1520 // Remove administrative keys
1521 $cache = $this->cache->get( $code );
1522 unset( $cache['VERSION'] );
1523 unset( $cache['EXPIRY'] );
1524 unset( $cache['EXCESSIVE'] );
1525 // Remove any !NONEXISTENT keys
1526 $cache = array_diff( $cache, [ '!NONEXISTENT' ] );
1527
1528 // Keys may appear with a capital first letter. lcfirst them.
1529 return array_map( $this->contLang->lcfirst( ... ), array_keys( $cache ) );
1530 }
1531
1540 public function updateMessageOverride( $page, ?Content $content = null ) {
1541 // treat null as not existing
1542 $msgText = $this->getMessageTextFromContent( $content ) ?? false;
1543
1544 $this->replace( $page->getDBkey(), $msgText );
1545
1546 if ( $this->contLangConverter->hasVariants() ) {
1547 $this->contLangConverter->updateConversionTable( $page );
1548 }
1549 }
1550
1555 public function getCheckKey( $code ) {
1556 return $this->wanCache->makeKey( 'messages', $code );
1557 }
1558
1563 private function getMessageTextFromContent( ?Content $content = null ) {
1564 // @TODO: could skip pseudo-messages like js/css here, based on content model
1565 if ( $content && $content->isRedirect() ) {
1566 // Treat redirects as not existing (T376398)
1567 $msgText = false;
1568 } elseif ( $content ) {
1569 // Message page exists...
1570 // XXX: Is this the right way to turn a Content object into a message?
1571 // NOTE: $content is typically either WikitextContent, JavaScriptContent or
1572 // CssContent.
1573 $msgText = $content->getWikitextForTransclusion();
1574 if ( $msgText === false || $msgText === null ) {
1575 // This might be due to some kind of misconfiguration...
1576 $msgText = null;
1577 $this->logger->warning(
1578 __METHOD__ . ": message content doesn't provide wikitext "
1579 . "(content model: " . $content->getModel() . ")" );
1580 }
1581 } else {
1582 // Message page does not exist...
1583 $msgText = false;
1584 }
1585
1586 return $msgText;
1587 }
1588
1594 private function bigMessageCacheKey( $hash, $title ) {
1595 return $this->wanCache->makeKey( 'messages-big', $hash, $title );
1596 }
1597}
1598
1600class_alias( MessageCache::class, 'MessageCache' );
const NS_MEDIAWIKI
Definition Defines.php:59
const NS_SPECIAL
Definition Defines.php:40
wfTimestampNow()
Convenience function; returns MediaWiki timestamp for the present time.
wfTimestamp( $outputtype=TS::UNIX, $ts=0)
Get a timestamp string in one of various formats.
if(MW_ENTRY_POINT==='index') if(!defined( 'MW_NO_SESSION') &&MW_ENTRY_POINT !=='cli') global $wgTitle
Definition Setup.php:529
if(!defined('MW_SETUP_CALLBACK'))
Definition WebStart.php:72
A class for passing options to services.
assertRequiredOptions(array $expectedKeys)
Assert that the list of options provided in this instance exactly match $expectedKeys,...
makeTitle( $linkId)
Convert a link ID to a Title.to override Title
This class provides an implementation of the core hook interfaces, forwarding hook calls to HookConta...
An interface for creating language converters.
getLanguageConverter( $language=null)
Provide a LanguageConverter for given language.
A service that provides utilities to do with language names and codes.
const DEFINED
Return in getLanguageName(s) only the languages that are defined by MediaWiki.
const AUTONYMS
Return autonyms in getLanguageName(s).
Base class for language-specific code.
Definition Language.php:65
Caching for the contents of localisation files.
Message cache purging and in-place update handler for specific message page changes.
Cache messages that are defined by MediaWiki-namespace pages or by hooks.
__construct(WANObjectCache $wanCache, BagOStuff $mainCache, BagOStuff $serverCache, Language $contLang, LanguageConverterFactory $langConverterFactory, LoggerInterface $logger, ServiceOptions $options, LocalisationCache $localisationCache, LanguageNameUtils $languageNameUtils, LanguageFallback $languageFallback, HookContainer $hookContainer, MessageParser $messageParser)
isDisabled()
Whether DB/cache usage is disabled for determining messages.
getMsgFromNamespace( $title, $code)
Get a message from the MediaWiki namespace, with caching.
const MAX_REQUEST_LANGUAGES
The size of the MapCacheLRU which stores message data.
parseWithPostprocessing(string $text, PageReference $contextPage, bool $linestart=true, bool $interface=false, $language=null)
replace( $title, $text)
Update the cache as necessary when a message page is changed.
getAllMessageKeys( $code)
Get all message keys stored in the message cache for a given language.
refreshAndReplaceInternal(string $code, array $replacements)
updateMessageOverride( $page, ?Content $content=null)
Purge message caches when a MediaWiki: page is created, updated, or deleted.
parse( $text, ?PageReference $page=null, $linestart=true, $interface=false, $language=null)
figureMessage( $key)
Given a title string possibly containing a slash, determine the message key and language code.
const CONSTRUCTOR_OPTIONS
Options to be included in the ServiceOptions.
transform( $message, $interface=false, $language=null, ?PageReference $page=null)
enable()
Re-enable the MessageCache if it was disabled by a call to disable().
normalizeKey(string $key)
Normalize message key input.
setLogger(LoggerInterface $logger)
disable( $logReason='')
Disable loading of messages from the MediaWiki namespace.
clear()
Clear all stored messages in global and local cache.
Class to hold extra information about the result of a MessageCache\get() call.
const MaxMsgCacheEntrySize
Name constant for the MaxMsgCacheEntrySize setting, for use with Config\get().
const AdaptiveMessageCache
Name constant for the AdaptiveMessageCache setting, for use with Config\get().
const UseXssLanguage
Name constant for the UseXssLanguage setting, for use with Config\get().
const UseDatabaseMessages
Name constant for the UseDatabaseMessages setting, for use with Config\get().
const RawHtmlMessages
Name constant for the RawHtmlMessages setting, for use with Config\get().
static getInstance()
Returns the global default instance of the top level service locator.
string $key
The message key.
Definition Message.php:192
Content null $content
Content object representing the message.
Definition Message.php:226
ParserOutput is a rendering of a Content object or a message.
bool[] $success
Map of (key => bool) to indicate success of each part of batch operations.
load(string $filePath, string $context='', bool $allowMissing=false)
Loads and decodes a JSON file.
Abstract class for any ephemeral data store.
Definition BagOStuff.php:73
No-op implementation that stores nothing.
Store key-value entries in a size-limited in-memory LRU cache.
Multi-datacenter aware caching interface.
Content of like value.
Definition LikeValue.php:14
return[ 'config-schema-inverse'=>['default'=>['ConfigRegistry'=>['main'=> 'MediaWiki\\Config\\GlobalVarConfig::newInstance',], 'Sitename'=> 'MediaWiki', 'Server'=> false, 'CanonicalServer'=> false, 'ServerName'=> false, 'AssumeProxiesUseDefaultProtocolPorts'=> true, 'HttpsPort'=> 443, 'ForceHTTPS'=> false, 'ScriptPath'=> '/wiki', 'UsePathInfo'=> null, 'Script'=> false, 'LoadScript'=> false, 'RestPath'=> false, 'StylePath'=> false, 'LocalStylePath'=> false, 'ExtensionAssetsPath'=> false, 'ExtensionDirectory'=> null, 'StyleDirectory'=> null, 'ArticlePath'=> false, 'UploadPath'=> false, 'ImgAuthPath'=> false, 'ThumbPath'=> false, 'UploadDirectory'=> false, 'FileCacheDirectory'=> false, 'Logo'=> false, 'Logos'=> false, 'Favicon'=> '/favicon.ico', 'AppleTouchIcon'=> false, 'ReferrerPolicy'=> false, 'TmpDirectory'=> false, 'UploadBaseUrl'=> '', 'UploadStashScalerBaseUrl'=> false, 'ActionPaths'=>[], 'MainPageIsDomainRoot'=> false, 'EnableUploads'=> false, 'UploadStashMaxAge'=> 21600, 'EnableAsyncUploads'=> false, 'EnableAsyncUploadsByURL'=> false, 'EnableChunkedUploads'=> false, 'UploadMaintenance'=> false, 'IllegalFileChars'=> ':\\/\\\\', 'DeletedDirectory'=> false, 'ImgAuthDetails'=> false, 'ImgAuthUrlPathMap'=>[], 'LocalFileRepo'=>['class'=> 'MediaWiki\\FileRepo\\LocalRepo', 'name'=> 'local', 'directory'=> null, 'scriptDirUrl'=> null, 'favicon'=> null, 'url'=> null, 'hashLevels'=> null, 'thumbScriptUrl'=> null, 'transformVia404'=> null, 'deletedDir'=> null, 'deletedHashLevels'=> null, 'updateCompatibleMetadata'=> null, 'reserializeMetadata'=> null,], 'ForeignFileRepos'=>[], 'UseInstantCommons'=> false, 'UseSharedUploads'=> false, 'SharedUploadDirectory'=> null, 'SharedUploadPath'=> null, 'HashedSharedUploadDirectory'=> true, 'RepositoryBaseUrl'=> 'https:'FetchCommonsDescriptions'=> false, 'SharedUploadDBname'=> false, 'SharedUploadDBprefix'=> '', 'SharedUploadDBschema'=> null, 'CacheSharedUploads'=> true, 'ForeignUploadTargets'=>['local',], 'UploadDialog'=>['fields'=>['description'=> true, 'date'=> false, 'categories'=> false,], 'licensemessages'=>['local'=> 'generic-local', 'foreign'=> 'generic-foreign',], 'comment'=>['local'=> '', 'foreign'=> '',], 'format'=>['filepage'=> ' $DESCRIPTION', 'description'=> ' $TEXT', 'ownwork'=> '', 'license'=> '', 'uncategorized'=> '',],], 'FileBackends'=>[], 'LockManagers'=>[], 'DefaultLockManager'=> null, 'ShowEXIF'=> null, 'UpdateCompatibleMetadata'=> false, 'AllowCopyUploads'=> false, 'CopyUploadsDomains'=>[], 'CopyUploadsFromSpecialUpload'=> false, 'CopyUploadProxy'=> false, 'CopyUploadTimeout'=> false, 'CopyUploadAllowOnWikiDomainConfig'=> false, 'MaxUploadSize'=> 104857600, 'MinUploadChunkSize'=> 1024, 'UploadNavigationUrl'=> false, 'UploadMissingFileUrl'=> false, 'ThumbnailScriptPath'=> false, 'SharedThumbnailScriptPath'=> false, 'HashedUploadDirectory'=> true, 'CSPUploadEntryPoint'=> true, 'FileExtensions'=>['png', 'gif', 'jpg', 'jpeg', 'webp',], 'ProhibitedFileExtensions'=>['html', 'htm', 'js', 'jsb', 'mhtml', 'mht', 'xhtml', 'xht', 'php', 'phtml', 'php3', 'php4', 'php5', 'phps', 'phar', 'shtml', 'jhtml', 'pl', 'py', 'cgi', 'exe', 'scr', 'dll', 'msi', 'vbs', 'bat', 'com', 'pif', 'cmd', 'vxd', 'cpl', 'xml',], 'MimeTypeExclusions'=>['text/html', 'application/javascript', 'text/javascript', 'text/x-javascript', 'application/x-shellscript', 'application/x-php', 'text/x-php', 'text/x-python', 'text/x-perl', 'text/x-bash', 'text/x-sh', 'text/x-csh', 'text/scriptlet', 'application/x-msdownload', 'application/x-msmetafile', 'application/java', 'application/xml', 'text/xml',], 'CheckFileExtensions'=> true, 'StrictFileExtensions'=> true, 'DisableUploadScriptChecks'=> false, 'UploadSizeWarning'=> false, 'TrustedMediaFormats'=>['BITMAP', 'AUDIO', 'VIDEO', 'image/svg+xml', 'application/pdf',], 'MediaHandlers'=>[], 'NativeImageLazyLoading'=> true, 'ParserTestMediaHandlers'=>['image/jpeg'=> 'MockBitmapHandler', 'image/png'=> 'MockBitmapHandler', 'image/gif'=> 'MockBitmapHandler', 'image/tiff'=> 'MockBitmapHandler', 'image/webp'=> 'MockBitmapHandler', 'image/x-ms-bmp'=> 'MockBitmapHandler', 'image/x-bmp'=> 'MockBitmapHandler', 'image/x-xcf'=> 'MockBitmapHandler', 'image/svg+xml'=> 'MockSvgHandler', 'image/vnd.djvu'=> 'MockDjVuHandler',], 'UseImageResize'=> true, 'UseImageMagick'=> false, 'ImageMagickConvertCommand'=> '/usr/bin/convert', 'MaxInterlacingAreas'=>[], 'SharpenParameter'=> '0x0.4', 'SharpenReductionThreshold'=> 0.85, 'ImageMagickTempDir'=> false, 'CustomConvertCommand'=> false, 'JpegTran'=> '/usr/bin/jpegtran', 'JpegPixelFormat'=> 'yuv420', 'JpegQuality'=> 80, 'Exiv2Command'=> '/usr/bin/exiv2', 'Exiftool'=> '/usr/bin/exiftool', 'SVGConverters'=>['ImageMagick'=> ' $path/convert -background "#ffffff00" -thumbnail $widthx$height\\! $input PNG:$output', 'inkscape'=> ' $path/inkscape -w $width -o $output $input', 'batik'=> 'java -Djava.awt.headless=true -jar $path/batik-rasterizer.jar -w $width -d $output $input', 'rsvg'=> ' $path/rsvg-convert -w $width -h $height -l $lang -o $output $input', 'ImagickExt'=>['SvgHandler::rasterizeImagickExt',],], 'SVGConverter'=> 'ImageMagick', 'SVGConverterPath'=> '', 'SVGMaxSize'=> 5120, 'SVGMetadataCutoff'=> 5242880, 'SVGNativeRendering'=> true, 'SVGNativeRenderingSizeLimit'=> 51200, 'MediaInTargetLanguage'=> true, 'MaxImageArea'=> 12500000, 'MaxAnimatedGifArea'=> 12500000, 'MaxAnimatedWebPArea'=> 12500000, 'TiffThumbnailType'=>[], 'ThumbnailEpoch'=> '20030516000000', 'AttemptFailureEpoch'=> 1, 'IgnoreImageErrors'=> false, 'GenerateThumbnailOnParse'=> true, 'ShowArchiveThumbnails'=> true, 'EnableAutoRotation'=> null, 'Antivirus'=> null, 'AntivirusSetup'=>['clamav'=>['command'=> 'clamscan --no-summary ', 'codemap'=>[0=> 0, 1=> 1, 52=> -1, ' *'=> false,], 'messagepattern'=> '/.*?:(.*)/sim',],], 'AntivirusRequired'=> true, 'VerifyMimeType'=> true, 'MimeTypeFile'=> 'internal', 'MimeInfoFile'=> 'internal', 'MimeDetectorCommand'=> null, 'TrivialMimeDetection'=> false, 'XMLMimeTypes'=>['http:'svg'=> 'image/svg+xml', 'http:'http:'html'=> 'text/html',], 'ImageLimits'=>[[320, 240,], [640, 480,], [800, 600,], [1024, 768,], [1280, 1024,], [2560, 2048,],], 'ThumbLimits'=>[120, 150, 180, 200, 220, 250, 300, 400,], 'ThumbnailNamespaces'=>[6,], 'ThumbnailSteps'=> null, 'ThumbnailBuckets'=> null, 'ThumbnailMinimumBucketDistance'=> 50, 'UploadThumbnailRenderMap'=>[], 'UploadThumbnailRenderMethod'=> 'jobqueue', 'UploadThumbnailRenderHttpCustomHost'=> false, 'UploadThumbnailRenderHttpCustomDomain'=> false, 'UseTinyRGBForJPGThumbnails'=> false, 'GalleryOptions'=>[], 'ThumbUpright'=> 0.75, 'DirectoryMode'=> 511, 'ResponsiveImages'=> true, 'ImagePreconnect'=> false, 'TrackMediaRequestProvenance'=> false, 'DjvuUseBoxedCommand'=> false, 'DjvuDump'=> null, 'DjvuRenderer'=> null, 'DjvuTxt'=> null, 'DjvuPostProcessor'=> 'pnmtojpeg', 'DjvuOutputExtension'=> 'jpg', 'EmergencyContact'=> false, 'PasswordSender'=> false, 'NoReplyAddress'=> false, 'EnableEmail'=> true, 'EnableUserEmail'=> true, 'UserEmailUseReplyTo'=> true, 'PasswordReminderResendTime'=> 24, 'NewPasswordExpiry'=> 604800, 'UserEmailConfirmationTokenExpiry'=> 604800, 'PasswordExpirationDays'=> false, 'PasswordExpireGrace'=> 604800, 'SMTP'=> false, 'AdditionalMailParams'=> null, 'AllowHTMLEmail'=> false, 'EnotifFromEditor'=> false, 'EmailAuthentication'=> true, 'EmailConfirmationBanner'=> false, 'EnotifWatchlist'=> false, 'EnotifUserTalk'=> false, 'EnotifRevealEditorAddress'=> false, 'EnotifMinorEdits'=> true, 'EnotifUseRealName'=> false, 'UsersNotifiedOnAllChanges'=>[], 'DBname'=> 'my_wiki', 'DBmwschema'=> null, 'DBprefix'=> '', 'DBserver'=> 'localhost', 'DBport'=> 5432, 'DBuser'=> 'wikiuser', 'DBpassword'=> '', 'DBtype'=> 'mysql', 'DBssl'=> false, 'DBcompress'=> false, 'DBStrictWarnings'=> false, 'DBadminuser'=> null, 'DBadminpassword'=> null, 'SearchType'=> null, 'SearchTypeAlternatives'=> null, 'DBTableOptions'=> 'ENGINE=InnoDB, DEFAULT CHARSET=binary', 'SQLMode'=> '', 'SQLiteDataDir'=> '', 'SharedDB'=> null, 'SharedPrefix'=> false, 'SharedTables'=>['user', 'user_properties', 'user_autocreate_serial',], 'SharedSchema'=> false, 'DBservers'=> false, 'LBFactoryConf'=>['class'=> 'Wikimedia\\Rdbms\\LBFactorySimple',], 'DataCenterUpdateStickTTL'=> 10, 'DBerrorLog'=> false, 'DBerrorLogTZ'=> false, 'LocalDatabases'=>[], 'DatabaseReplicaLagWarning'=> 10, 'DatabaseReplicaLagCritical'=> 30, 'MaxExecutionTimeForExpensiveQueries'=> 0, 'VirtualDomainsMapping'=>[], 'RemoteVirtualDomainsMapping'=>[], 'FileSchemaMigrationStage'=> 3, 'ExternalLinksDomainGaps'=>[], 'ContentHandlers'=>['wikitext'=>['class'=> 'MediaWiki\\Content\\WikitextContentHandler', 'services'=>['TitleFactory', 'ParserFactory', 'GlobalIdGenerator', 'LanguageNameUtils', 'LinkRenderer', 'MagicWordFactory', 'ParsoidParserFactory',],], 'javascript'=>['class'=> 'MediaWiki\\Content\\JavaScriptContentHandler', 'services'=>['MainConfig', 'ParserFactory', 'UserOptionsLookup', 'CodeHighlighter',],], 'json'=>['class'=> 'MediaWiki\\Content\\JsonContentHandler', 'services'=>['ParsoidParserFactory', 'TitleFactory',],], 'css'=>['class'=> 'MediaWiki\\Content\\CssContentHandler', 'services'=>['MainConfig', 'ParserFactory', 'UserOptionsLookup', 'CodeHighlighter',],], 'vue'=>['class'=> 'MediaWiki\\Content\\VueContentHandler', 'services'=>['MainConfig', 'ParserFactory', 'CodeHighlighter',],], 'text'=> 'MediaWiki\\Content\\TextContentHandler', 'unknown'=> 'MediaWiki\\Content\\FallbackContentHandler',], 'NamespaceContentModels'=>[], 'TextModelsToParse'=>['wikitext', 'javascript', 'css',], 'CompressRevisions'=> false, 'ExternalStores'=>[], 'ExternalServers'=>[], 'DefaultExternalStore'=> false, 'RevisionCacheExpiry'=> 604800, 'PageLanguageUseDB'=> false, 'DiffEngine'=> null, 'ExternalDiffEngine'=> false, 'Wikidiff2Options'=>[], 'RequestTimeLimit'=> null, 'TransactionalTimeLimit'=> 120, 'CriticalSectionTimeLimit'=> 180.0, 'MiserMode'=> false, 'DisableQueryPages'=> false, 'QueryCacheLimit'=> 1000, 'WantedPagesThreshold'=> 1, 'AllowSlowParserFunctions'=> false, 'AllowSchemaUpdates'=> true, 'MaxArticleSize'=> 2048, 'MemoryLimit'=> '50M', 'PoolCounterConf'=> null, 'PoolCountClientConf'=>['servers'=>['127.0.0.1',], 'timeout'=> 0.1,], 'MaxUserDBWriteDuration'=> false, 'MaxJobDBWriteDuration'=> false, 'LinkHolderBatchSize'=> 1000, 'MaximumMovedPages'=> 100, 'ForceDeferredUpdatesPreSend'=> false, 'MultiShardSiteStats'=> false, 'CacheDirectory'=> false, 'MainCacheType'=> 0, 'MessageCacheType'=> -1, 'ParserCacheType'=> -1, 'SessionCacheType'=> -1, 'AnonSessionCacheType'=> false, 'LanguageConverterCacheType'=> -1, 'ObjectCaches'=>[0=>['class'=> 'Wikimedia\\ObjectCache\\EmptyBagOStuff', 'reportDupes'=> false,], 1=>['class'=> 'MediaWiki\\ObjectCache\\SqlBagOStuff', 'loggroup'=> 'SQLBagOStuff',], 'memcached-php'=>['class'=> 'Wikimedia\\ObjectCache\\MemcachedPhpBagOStuff', 'loggroup'=> 'memcached',], 'memcached-pecl'=>['class'=> 'Wikimedia\\ObjectCache\\MemcachedPeclBagOStuff', 'loggroup'=> 'memcached',], 'hash'=>['class'=> 'Wikimedia\\ObjectCache\\HashBagOStuff', 'reportDupes'=> false,], 'apc'=>['class'=> 'Wikimedia\\ObjectCache\\APCUBagOStuff', 'reportDupes'=> false,], 'apcu'=>['class'=> 'Wikimedia\\ObjectCache\\APCUBagOStuff', 'reportDupes'=> false,],], 'WANObjectCache'=>[], 'MicroStashType'=> -1, 'MainStash'=> 1, 'ParsoidCacheConfig'=>['StashType'=> null, 'StashDuration'=> 86400,], 'ParsoidSelectiveUpdateSampleRate'=> 0, 'SplitParsoidParserCache'=> false, 'ParserCacheFilterConfig'=>['pcache'=>['default'=>['minCpuTime'=> 0,],], 'postproc-pcache'=>['default'=>['minCpuTime'=> 9223372036854775807,],], 'parsoid-pcache'=>['default'=>['minCpuTime'=> 0,],], 'postproc-parsoid-pcache'=>['default'=>['minCpuTime'=> 0,],],], 'ChronologyProtectorSecret'=> '', 'ParserCacheExpireTime'=> 86400, 'ParserCacheAsyncExpireTime'=> 60, 'ParserCacheAsyncRefreshJobs'=> true, 'OldRevisionParserCacheExpireTime'=> 3600, 'ObjectCacheSessionExpiry'=> 3600, 'SuspiciousIpExpiry'=> false, 'SessionPbkdf2Iterations'=> 10001, 'UseSessionCookieJwt'=> false, 'JwtSessionCookieIssuer'=> null, 'MemCachedServers'=>['127.0.0.1:11211',], 'MemCachedPersistent'=> false, 'MemCachedTimeout'=> 500000, 'UseLocalMessageCache'=> false, 'AdaptiveMessageCache'=> false, 'LocalisationCacheConf'=>['class'=> 'MediaWiki\\Language\\LocalisationCache', 'store'=> 'detect', 'storeClass'=> false, 'storeDirectory'=> false, 'storeServer'=>[], 'forceRecache'=> false, 'manualRecache'=> false,], 'CachePages'=> true, 'CacheEpoch'=> '20030516000000', 'GitInfoCacheDirectory'=> false, 'UseFileCache'=> false, 'FileCacheDepth'=> 2, 'RenderHashAppend'=> '', 'EnableSidebarCache'=> false, 'SidebarCacheExpiry'=> 86400, 'UseGzip'=> false, 'InvalidateCacheOnLocalSettingsChange'=> true, 'ExtensionInfoMTime'=> false, 'EnableRemoteBagOStuffTests'=> false, 'UseCdn'=> false, 'VaryOnXFP'=> false, 'InternalServer'=> false, 'CdnMaxAge'=> 18000, 'CdnMaxageLagged'=> 30, 'CdnMaxageStale'=> 10, 'CdnReboundPurgeDelay'=> 0, 'CdnMaxageSubstitute'=> 60, 'CdnServers'=>[], 'CdnServersNoPurge'=>[], 'HTCPRouting'=>[], 'HTCPMulticastTTL'=> 1, 'UsePrivateIPs'=> false, 'CdnMatchParameterOrder'=> true, 'LanguageCode'=> 'en', 'GrammarForms'=>[], 'InterwikiMagic'=> true, 'HideInterlanguageLinks'=> false, 'ExtraInterlanguageLinkPrefixes'=>[], 'InterlanguageLinkCodeMap'=>[], 'ExtraLanguageNames'=>[], 'ExtraLanguageCodes'=>['bh'=> 'bho', 'no'=> 'nb', 'simple'=> 'en',], 'DummyLanguageCodes'=>[], 'AllUnicodeFixes'=> false, 'LegacyEncoding'=> false, 'AmericanDates'=> false, 'TranslateNumerals'=> true, 'UseDatabaseMessages'=> true, 'MaxMsgCacheEntrySize'=> 10000, 'DisableLangConversion'=> false, 'DisableTitleConversion'=> false, 'DefaultLanguageVariant'=> false, 'UsePigLatinVariant'=> false, 'DisabledVariants'=>[], 'VariantArticlePath'=> false, 'UseXssLanguage'=> false, 'LoginLanguageSelector'=> false, 'ForceUIMsgAsContentMsg'=>[], 'RawHtmlMessages'=>[], 'Localtimezone'=> null, 'LocalTZoffset'=> null, 'OverrideUcfirstCharacters'=>[], 'MimeType'=> 'text/html', 'Html5Version'=> null, 'EditSubmitButtonLabelPublish'=> false, 'XhtmlNamespaces'=>[], 'SiteNotice'=> '', 'BrowserFormatDetection'=> 'telephone=no', 'SkinMetaTags'=>[], 'DefaultSkin'=> 'vector-2022', 'FallbackSkin'=> 'fallback', 'SkipSkins'=>[], 'DisableOutputCompression'=> false, 'FragmentMode'=>['html5', 'legacy',], 'ExternalInterwikiFragmentMode'=> 'legacy', 'FooterIcons'=>['copyright'=>['copyright'=>[],], 'poweredby'=>['mediawiki'=>['src'=> null, 'url'=> 'https:'alt'=> 'Powered by MediaWiki', 'lang'=> 'en',],],], 'EnableSectionShare'=> false, 'PageShareSkinsEnabled'=>[], 'UseCombinedLoginLink'=> false, 'Edititis'=> false, 'Send404Code'=> true, 'ShowRollbackEditCount'=> 10, 'EnableCanonicalServerLink'=> false, 'InterwikiLogoOverride'=>[], 'ResourceModules'=>[], 'ResourceModuleSkinStyles'=>[], 'ResourceLoaderSources'=>[], 'ResourceBasePath'=> null, 'ResourceLoaderMaxage'=>[], 'ResourceLoaderDebug'=> false, 'ResourceLoaderMaxQueryLength'=> false, 'ResourceLoaderValidateJS'=> true, 'ResourceLoaderEnableJSProfiler'=> false, 'ResourceLoaderStorageEnabled'=> true, 'ResourceLoaderStorageVersion'=> 1, 'ResourceLoaderEnableSourceMapLinks'=> true, 'AllowSiteCSSOnRestrictedPages'=> false, 'VueDevelopmentMode'=> false, 'CodexDevelopmentDir'=> null, 'MetaNamespace'=> false, 'MetaNamespaceTalk'=> false, 'CanonicalNamespaceNames'=>[-2=> 'Media', -1=> 'Special', 0=> '', 1=> 'Talk', 2=> 'User', 3=> 'User_talk', 4=> 'Project', 5=> 'Project_talk', 6=> 'File', 7=> 'File_talk', 8=> 'MediaWiki', 9=> 'MediaWiki_talk', 10=> 'Template', 11=> 'Template_talk', 12=> 'Help', 13=> 'Help_talk', 14=> 'Category', 15=> 'Category_talk',], 'ExtraNamespaces'=>[], 'ExtraGenderNamespaces'=>[], 'NamespaceAliases'=>[], 'LegalTitleChars'=> ' %!"$&\'()*,\\-.\\/0-9:;=?@A-Z\\\\^_`a-z~\\x80-\\xFF+', 'CapitalLinks' => true, 'CapitalLinkOverrides' => [ ], 'NamespacesWithSubpages' => [ 1 => true, 2 => true, 3 => true, 4 => true, 5 => true, 7 => true, 8 => true, 9 => true, 10 => true, 11 => true, 12 => true, 13 => true, 15 => true, ], 'NamespacesWithoutAutoSummaries' => [ ], 'ContentNamespaces' => [ 0, ], 'ShortPagesNamespaceExclusions' => [ ], 'ExtraSignatureNamespaces' => [ ], 'InvalidRedirectTargets' => [ 'Filepath', 'Mypage', 'Mytalk', 'Redirect', 'Mylog', ], 'DisableHardRedirects' => false, 'FixDoubleRedirects' => false, 'LocalInterwikis' => [ ], 'InterwikiExpiry' => 10800, 'InterwikiCache' => false, 'InterwikiScopes' => 3, 'InterwikiFallbackSite' => 'wiki', 'RedirectSources' => false, 'SiteTypes' => [ 'mediawiki' => 'MediaWiki\\Site\\MediaWikiSite', ], 'MaxTocLevel' => 999, 'MaxPPNodeCount' => 1000000, 'MaxTemplateDepth' => 100, 'MaxPPExpandDepth' => 100, 'UrlProtocols' => [ 'bitcoin:', 'ftp: 'ftps: 'geo:', 'git: 'gopher: 'http: 'https: 'irc: 'ircs: 'magnet:', 'mailto:', 'matrix:', 'mms: 'news:', 'nntp: 'redis: 'sftp: 'sip:', 'sips:', 'sms:', 'ssh: 'svn: 'tel:', 'telnet: 'urn:', 'wikipedia: 'worldwind: 'xmpp:', ' ], 'CleanSignatures' => true, 'AllowExternalImages' => false, 'AllowExternalImagesFrom' => '', 'EnableImageWhitelist' => false, 'TidyConfig' => [ ], 'ParsoidSettings' => [ 'useSelser' => true, ], 'ParsoidExperimentalParserFunctionOutput' => false, 'RawHtml' => false, 'ExternalLinkTarget' => false, 'NoFollowLinks' => true, 'NoFollowNsExceptions' => [ ], 'NoFollowDomainExceptions' => [ 'mediawiki.org', ], 'RegisterInternalExternals' => false, 'ExternalLinksIgnoreDomains' => [ ], 'AllowDisplayTitle' => true, 'RestrictDisplayTitle' => true, 'ExpensiveParserFunctionLimit' => 100, 'PreprocessorCacheThreshold' => 1000, 'EnableScaryTranscluding' => false, 'TranscludeCacheExpiry' => 3600, 'EnableMagicLinks' => [ 'ISBN' => false, 'PMID' => false, 'RFC' => false, ], 'ParserEnableUserLanguage' => false, 'ArticleCountMethod' => 'link', 'ActiveUserDays' => 30, 'LearnerEdits' => 10, 'LearnerMemberSince' => 4, 'ExperiencedUserEdits' => 500, 'ExperiencedUserMemberSince' => 30, 'ManualRevertSearchRadius' => 15, 'RevertedTagMaxDepth' => 15, 'CentralIdLookupProviders' => [ 'local' => [ 'class' => 'MediaWiki\\User\\CentralId\\LocalIdLookup', 'services' => [ 'MainConfig', 'DBLoadBalancerFactory', 'HideUserUtils', ], ], ], 'CentralIdLookupProvider' => 'local', 'UserRegistrationProviders' => [ 'local' => [ 'class' => 'MediaWiki\\User\\Registration\\LocalUserRegistrationProvider', 'services' => [ 'ConnectionProvider', ], ], ], 'PasswordPolicy' => [ 'policies' => [ 'bureaucrat' => [ 'MinimalPasswordLength' => 10, 'MinimumPasswordLengthToLogin' => 1, ], 'sysop' => [ 'MinimalPasswordLength' => 10, 'MinimumPasswordLengthToLogin' => 1, ], 'interface-admin' => [ 'MinimalPasswordLength' => 10, 'MinimumPasswordLengthToLogin' => 1, ], 'bot' => [ 'MinimalPasswordLength' => 10, 'MinimumPasswordLengthToLogin' => 1, ], 'default' => [ 'MinimalPasswordLength' => [ 'value' => 8, 'suggestChangeOnLogin' => true, ], 'PasswordCannotBeSubstringInUsername' => [ 'value' => true, 'suggestChangeOnLogin' => true, ], 'PasswordCannotMatchDefaults' => [ 'value' => true, 'suggestChangeOnLogin' => true, ], 'MaximalPasswordLength' => [ 'value' => 4096, 'suggestChangeOnLogin' => true, ], 'PasswordNotInCommonList' => [ 'value' => true, 'suggestChangeOnLogin' => true, ], ], ], 'checks' => [ 'MinimalPasswordLength' => [ 'MediaWiki\\Password\\PasswordPolicyChecks', 'checkMinimalPasswordLength', ], 'MinimumPasswordLengthToLogin' => [ 'MediaWiki\\Password\\PasswordPolicyChecks', 'checkMinimumPasswordLengthToLogin', ], 'PasswordCannotBeSubstringInUsername' => [ 'MediaWiki\\Password\\PasswordPolicyChecks', 'checkPasswordCannotBeSubstringInUsername', ], 'PasswordCannotMatchDefaults' => [ 'MediaWiki\\Password\\PasswordPolicyChecks', 'checkPasswordCannotMatchDefaults', ], 'MaximalPasswordLength' => [ 'MediaWiki\\Password\\PasswordPolicyChecks', 'checkMaximalPasswordLength', ], 'PasswordNotInCommonList' => [ 'MediaWiki\\Password\\PasswordPolicyChecks', 'checkPasswordNotInCommonList', ], ], ], 'AuthManagerConfig' => null, 'AuthManagerAutoConfig' => [ 'preauth' => [ 'MediaWiki\\Auth\\ThrottlePreAuthenticationProvider' => [ 'class' => 'MediaWiki\\Auth\\ThrottlePreAuthenticationProvider', 'sort' => 0, ], 'MediaWiki\\Auth\\PreviouslyRenamedAccountPreAuthenticationProvider' => [ 'class' => 'MediaWiki\\Auth\\PreviouslyRenamedAccountPreAuthenticationProvider', 'services' => [ 'ConnectionProvider', 'UserFactory', ], 'sort' => 0, ], ], 'primaryauth' => [ 'MediaWiki\\Auth\\TemporaryPasswordPrimaryAuthenticationProvider' => [ 'class' => 'MediaWiki\\Auth\\TemporaryPasswordPrimaryAuthenticationProvider', 'services' => [ 'DBLoadBalancerFactory', 'UserOptionsLookup', ], 'args' => [ [ 'authoritative' => false, ], ], 'sort' => 0, ], 'MediaWiki\\Auth\\LocalPasswordPrimaryAuthenticationProvider' => [ 'class' => 'MediaWiki\\Auth\\LocalPasswordPrimaryAuthenticationProvider', 'services' => [ 'DBLoadBalancerFactory', ], 'args' => [ [ 'authoritative' => true, ], ], 'sort' => 100, ], ], 'secondaryauth' => [ 'MediaWiki\\Auth\\CheckBlocksSecondaryAuthenticationProvider' => [ 'class' => 'MediaWiki\\Auth\\CheckBlocksSecondaryAuthenticationProvider', 'sort' => 0, ], 'MediaWiki\\Auth\\ResetPasswordSecondaryAuthenticationProvider' => [ 'class' => 'MediaWiki\\Auth\\ResetPasswordSecondaryAuthenticationProvider', 'sort' => 100, ], 'MediaWiki\\Auth\\EmailNotificationSecondaryAuthenticationProvider' => [ 'class' => 'MediaWiki\\Auth\\EmailNotificationSecondaryAuthenticationProvider', 'services' => [ 'DBLoadBalancerFactory', ], 'sort' => 200, ], ], ], 'RememberMe' => 'choose', 'ReauthenticateTime' => [ 'default' => 3600, ], 'ChangeCredentialsBlacklist' => [ 'MediaWiki\\Auth\\TemporaryPasswordAuthenticationRequest', ], 'RemoveCredentialsBlacklist' => [ 'MediaWiki\\Auth\\PasswordAuthenticationRequest', ], 'InvalidPasswordReset' => true, 'PasswordDefault' => 'pbkdf2', 'PasswordConfig' => [ 'A' => [ 'class' => 'MediaWiki\\Password\\MWOldPassword', ], 'B' => [ 'class' => 'MediaWiki\\Password\\MWSaltedPassword', ], 'pbkdf2-legacyA' => [ 'class' => 'MediaWiki\\Password\\LayeredParameterizedPassword', 'types' => [ 'A', 'pbkdf2', ], ], 'pbkdf2-legacyB' => [ 'class' => 'MediaWiki\\Password\\LayeredParameterizedPassword', 'types' => [ 'B', 'pbkdf2', ], ], 'bcrypt' => [ 'class' => 'MediaWiki\\Password\\BcryptPassword', 'cost' => 9, ], 'pbkdf2' => [ 'class' => 'MediaWiki\\Password\\Pbkdf2PasswordUsingOpenSSL', 'algo' => 'sha512', 'cost' => '30000', 'length' => '64', ], 'argon2' => [ 'class' => 'MediaWiki\\Password\\Argon2Password', 'algo' => 'auto', ], ], 'PasswordResetRoutes' => [ 'username' => true, 'email' => true, ], 'MaxSigChars' => 255, 'SignatureValidation' => 'warning', 'SignatureAllowedLintErrors' => [ 'obsolete-tag', ], 'MaxNameChars' => 255, 'ReservedUsernames' => [ 'MediaWiki default', 'Conversion script', 'Maintenance script', 'Template namespace initialisation script', 'ScriptImporter', 'Delete page script', 'Move page script', 'Command line script', 'Unknown user', 'msg:double-redirect-fixer', 'msg:usermessage-editor', 'msg:proxyblocker', 'msg:sorbs', 'msg:spambot_username', 'msg:autochange-username', ], 'DefaultUserOptions' => [ 'ccmeonemails' => 0, 'date' => 'default', 'diffonly' => 0, 'diff-type' => 'table', 'disablemail' => 0, 'editfont' => 'monospace', 'editondblclick' => 0, 'editrecovery' => 0, 'editsectiononrightclick' => 0, 'email-allow-new-users' => 1, 'enotifminoredits' => 0, 'enotifrevealaddr' => 0, 'enotifusertalkpages' => 1, 'enotifwatchlistpages' => 1, 'extendwatchlist' => 1, 'fancysig' => 0, 'forceeditsummary' => 0, 'forcesafemode' => 0, 'gender' => 'unknown', 'hidecategorization' => 1, 'hideminor' => 0, 'hidepatrolled' => 0, 'imagesize' => 2, 'minordefault' => 0, 'newpageshidepatrolled' => 0, 'nickname' => '', 'norollbackdiff' => 0, 'prefershttps' => 1, 'previewonfirst' => 0, 'previewontop' => 1, 'pst-cssjs' => 1, 'rcdays' => 7, 'rcenhancedfilters-disable' => 0, 'rclimit' => 50, 'requireemail' => 0, 'search-match-redirect' => true, 'search-special-page' => 'Search', 'search-thumbnail-extra-namespaces' => true, 'searchlimit' => 20, 'showhiddencats' => 0, 'shownumberswatching' => 1, 'showrollbackconfirmation' => 0, 'skin' => false, 'skin-responsive' => 1, 'thumbsize' => 5, 'underline' => 2, 'useeditwarning' => 1, 'uselivepreview' => 0, 'usenewrc' => 1, 'watchcreations' => 1, 'watchcreations-expiry' => 'infinite', 'watchdefault' => 1, 'watchdefault-expiry' => 'infinite', 'watchdeletion' => 0, 'watchlistdays' => 7, 'watchlisthideanons' => 0, 'watchlisthidebots' => 0, 'watchlisthidecategorization' => 1, 'watchlisthideliu' => 0, 'watchlisthideminor' => 0, 'watchlisthideown' => 0, 'watchlisthidepatrolled' => 0, 'watchlistreloadautomatically' => 0, 'watchlistunwatchlinks' => 0, 'watchmoves' => 0, 'watchrollback' => 0, 'watchuploads' => 1, 'watchrollback-expiry' => 'infinite', 'watchstar-expiry' => 'infinite', 'wlenhancedfilters-disable' => 0, 'wllimit' => 250, ], 'ConditionalUserOptions' => [ ], 'HiddenPrefs' => [ ], 'UserJsPrefLimit' => 100, 'InvalidUsernameCharacters' => '@:>=', 'UserrightsInterwikiDelimiter' => '@', 'SecureLogin' => false, 'AuthenticationTokenVersion' => null, 'SessionProviders' => [ 'MediaWiki\\Session\\CookieSessionProvider' => [ 'class' => 'MediaWiki\\Session\\CookieSessionProvider', 'args' => [ [ 'priority' => 30, ], ], 'services' => [ 'JwtCodec', 'UrlUtils', ], ], 'MediaWiki\\Session\\BotPasswordSessionProvider' => [ 'class' => 'MediaWiki\\Session\\BotPasswordSessionProvider', 'args' => [ [ 'priority' => 75, ], ], 'services' => [ 'GrantsInfo', ], ], ], 'AutoCreateTempUser' => [ 'known' => false, 'enabled' => false, 'actions' => [ 'edit', ], 'genPattern' => '~$1', 'matchPattern' => null, 'reservedPattern' => '~$1', 'serialProvider' => [ 'type' => 'local', 'useYear' => true, ], 'serialMapping' => [ 'type' => 'readable-numeric', ], 'expireAfterDays' => 90, 'notifyBeforeExpirationDays' => 10, ], 'AutoblockExemptions' => [ ], 'AutoblockExpiry' => 86400, 'BlockAllowsUTEdit' => true, 'BlockCIDRLimit' => [ 'IPv4' => 16, 'IPv6' => 19, ], 'BlockDisablesLogin' => false, 'EnableMultiBlocks' => false, 'WhitelistRead' => false, 'WhitelistReadRegexp' => false, 'EmailConfirmToEdit' => false, 'HideIdentifiableRedirects' => true, 'GroupPermissions' => [ '*' => [ 'createaccount' => true, 'autocreateaccount' => true, 'read' => true, 'edit' => true, 'createpage' => true, 'createtalk' => true, 'viewmyprivateinfo' => true, 'editmyprivateinfo' => true, 'editmyoptions' => true, ], 'user' => [ 'move' => true, 'move-subpages' => true, 'move-rootuserpages' => true, 'move-categorypages' => true, 'movefile' => true, 'read' => true, 'edit' => true, 'createpage' => true, 'createtalk' => true, 'upload' => true, 'reupload' => true, 'reupload-shared' => true, 'minoredit' => true, 'editmyusercss' => true, 'editmyuserjson' => true, 'editmyuserjs' => true, 'editmyuserjsredirect' => true, 'sendemail' => true, 'applychangetags' => true, 'changetags' => true, 'viewmywatchlist' => true, 'editmywatchlist' => true, 'createwithcontentmodel' => true, 'logout' => true, ], 'autoconfirmed' => [ 'autoconfirmed' => true, 'editsemiprotected' => true, ], 'bot' => [ 'bot' => true, 'autoconfirmed' => true, 'editsemiprotected' => true, 'nominornewtalk' => true, 'autopatrol' => true, 'suppressredirect' => true, 'apihighlimits' => true, ], 'sysop' => [ 'block' => true, 'createaccount' => true, 'createpreviouslyrenamedaccount' => true, 'delete' => true, 'bigdelete' => true, 'deletedhistory' => true, 'deletedtext' => true, 'undelete' => true, 'editcontentmodel' => true, 'editinterface' => true, 'editsitejson' => true, 'edituserjson' => true, 'import' => true, 'importupload' => true, 'move' => true, 'move-subpages' => true, 'move-rootuserpages' => true, 'move-categorypages' => true, 'patrol' => true, 'autopatrol' => true, 'protect' => true, 'editprotected' => true, 'rollback' => true, 'upload' => true, 'reupload' => true, 'reupload-shared' => true, 'unwatchedpages' => true, 'autoconfirmed' => true, 'editsemiprotected' => true, 'ipblock-exempt' => true, 'blockemail' => true, 'markbotedits' => true, 'apihighlimits' => true, 'browsearchive' => true, 'noratelimit' => true, 'movefile' => true, 'unblockself' => true, 'suppressredirect' => true, 'mergehistory' => true, 'managechangetags' => true, 'deletechangetags' => true, ], 'interface-admin' => [ 'editinterface' => true, 'editsitecss' => true, 'editsitejson' => true, 'editsitejs' => true, 'editusercss' => true, 'edituserjson' => true, 'edituserjs' => true, ], 'bureaucrat' => [ 'userrights' => true, 'noratelimit' => true, 'renameuser' => true, ], 'suppress' => [ 'hideuser' => true, 'suppressrevision' => true, 'viewsuppressed' => true, 'suppressionlog' => true, 'deleterevision' => true, 'deletelogentry' => true, ], ], 'PrivilegedGroups' => [ 'bureaucrat', 'interface-admin', 'suppress', 'sysop', ], 'RevokePermissions' => [ ], 'GroupInheritsPermissions' => [ ], 'ImplicitGroups' => [ '*', 'user', 'autoconfirmed', ], 'GroupsAddToSelf' => [ ], 'GroupsRemoveFromSelf' => [ ], 'RestrictedGroups' => [ ], 'UserRequirementsPrivateConditions' => [ ], 'RestrictionTypes' => [ 'create', 'edit', 'move', 'upload', ], 'RestrictionLevels' => [ '', 'autoconfirmed', 'sysop', ], 'CascadingRestrictionLevels' => [ 'sysop', ], 'SemiprotectedRestrictionLevels' => [ 'autoconfirmed', ], 'NamespaceProtection' => [ ], 'RestrictUserPageEditing' => false, 'NonincludableNamespaces' => [ ], 'AutoConfirmAge' => 0, 'AutoConfirmCount' => 0, 'Autopromote' => [ 'autoconfirmed' => [ '&', [ 1, null, ], [ 2, null, ], ], ], 'AutopromoteOnce' => [ 'onEdit' => [ ], ], 'AutopromoteOnceLogInRC' => true, 'AutopromoteOnceRCExcludedGroups' => [ ], 'AddGroups' => [ ], 'RemoveGroups' => [ ], 'AvailableRights' => [ ], 'ImplicitRights' => [ ], 'DeleteRevisionsLimit' => 0, 'DeleteRevisionsBatchSize' => 1000, 'HideUserContribLimit' => 1000, 'AccountCreationThrottle' => [ [ 'count' => 0, 'seconds' => 86400, ], ], 'TempAccountCreationThrottle' => [ [ 'count' => 1, 'seconds' => 600, ], [ 'count' => 6, 'seconds' => 86400, ], ], 'TempAccountNameAcquisitionThrottle' => [ [ 'count' => 60, 'seconds' => 86400, ], ], 'SpamRegex' => [ ], 'SummarySpamRegex' => [ ], 'EnableDnsBlacklist' => false, 'DnsBlacklistUrls' => [ ], 'ProxyList' => [ ], 'ProxyWhitelist' => [ ], 'SoftBlockRanges' => [ ], 'ApplyIpBlocksToXff' => false, 'RateLimits' => [ 'edit' => [ 'ip' => [ 8, 60, ], 'newbie' => [ 8, 60, ], 'user' => [ 90, 60, ], ], 'move' => [ 'newbie' => [ 2, 120, ], 'user' => [ 8, 60, ], ], 'upload' => [ 'ip' => [ 8, 60, ], 'newbie' => [ 8, 60, ], ], 'rollback' => [ 'user' => [ 10, 60, ], 'newbie' => [ 5, 120, ], ], 'mailpassword' => [ 'ip' => [ 5, 3600, ], ], 'sendemail' => [ 'ip' => [ 5, 86400, ], 'newbie' => [ 5, 86400, ], 'user' => [ 20, 86400, ], ], 'changeemail' => [ 'ip-all' => [ 10, 3600, ], 'user' => [ 4, 86400, ], ], 'confirmemail' => [ 'ip-all' => [ 10, 3600, ], 'user' => [ 4, 86400, ], ], 'purge' => [ 'ip' => [ 30, 60, ], 'user' => [ 30, 60, ], ], 'linkpurge' => [ 'ip' => [ 30, 60, ], 'user' => [ 30, 60, ], ], 'renderfile' => [ 'ip' => [ 700, 30, ], 'user' => [ 700, 30, ], ], 'renderfile-nonstandard' => [ 'ip' => [ 70, 30, ], 'user' => [ 70, 30, ], ], 'stashedit' => [ 'ip' => [ 30, 60, ], 'newbie' => [ 30, 60, ], ], 'stashbasehtml' => [ 'ip' => [ 5, 60, ], 'newbie' => [ 5, 60, ], ], 'changetags' => [ 'ip' => [ 8, 60, ], 'newbie' => [ 8, 60, ], ], 'editcontentmodel' => [ 'newbie' => [ 2, 120, ], 'user' => [ 8, 60, ], ], ], 'RateLimitsExcludedIPs' => [ ], 'PutIPinRC' => true, 'QueryPageDefaultLimit' => 50, 'ExternalQuerySources' => [ ], 'PasswordAttemptThrottle' => [ [ 'count' => 5, 'seconds' => 300, ], [ 'count' => 150, 'seconds' => 172800, ], ], 'GrantPermissions' => [ 'basic' => [ 'autocreateaccount' => true, 'autoconfirmed' => true, 'autopatrol' => true, 'editsemiprotected' => true, 'ipblock-exempt' => true, 'nominornewtalk' => true, 'patrolmarks' => true, 'read' => true, 'unwatchedpages' => true, ], 'highvolume' => [ 'bot' => true, 'apihighlimits' => true, 'noratelimit' => true, 'markbotedits' => true, ], 'import' => [ 'import' => true, 'importupload' => true, ], 'editpage' => [ 'edit' => true, 'minoredit' => true, 'applychangetags' => true, 'changetags' => true, 'editcontentmodel' => true, 'createwithcontentmodel' => true, 'pagelang' => true, ], 'editprotected' => [ 'edit' => true, 'minoredit' => true, 'applychangetags' => true, 'changetags' => true, 'editcontentmodel' => true, 'createwithcontentmodel' => true, 'editprotected' => true, ], 'editmycssjs' => [ 'edit' => true, 'minoredit' => true, 'applychangetags' => true, 'changetags' => true, 'editcontentmodel' => true, 'createwithcontentmodel' => true, 'editmyusercss' => true, 'editmyuserjson' => true, 'editmyuserjs' => true, ], 'editmyoptions' => [ 'editmyoptions' => true, 'editmyuserjson' => true, ], 'editinterface' => [ 'edit' => true, 'minoredit' => true, 'applychangetags' => true, 'changetags' => true, 'editcontentmodel' => true, 'createwithcontentmodel' => true, 'editinterface' => true, 'edituserjson' => true, 'editsitejson' => true, ], 'editsiteconfig' => [ 'edit' => true, 'minoredit' => true, 'applychangetags' => true, 'changetags' => true, 'editcontentmodel' => true, 'createwithcontentmodel' => true, 'editinterface' => true, 'edituserjson' => true, 'editsitejson' => true, 'editusercss' => true, 'edituserjs' => true, 'editsitecss' => true, 'editsitejs' => true, ], 'createeditmovepage' => [ 'edit' => true, 'minoredit' => true, 'applychangetags' => true, 'changetags' => true, 'editcontentmodel' => true, 'createwithcontentmodel' => true, 'createpage' => true, 'createtalk' => true, 'delete-redirect' => true, 'move' => true, 'move-rootuserpages' => true, 'move-subpages' => true, 'move-categorypages' => true, 'suppressredirect' => true, ], 'uploadfile' => [ 'upload' => true, 'reupload-own' => true, ], 'uploadeditmovefile' => [ 'upload' => true, 'reupload-own' => true, 'reupload' => true, 'reupload-shared' => true, 'upload_by_url' => true, 'movefile' => true, 'suppressredirect' => true, ], 'patrol' => [ 'patrol' => true, ], 'rollback' => [ 'rollback' => true, ], 'blockusers' => [ 'block' => true, 'blockemail' => true, 'deferredblock' => true, ], 'viewdeleted' => [ 'browsearchive' => true, 'deletedhistory' => true, 'deletedtext' => true, ], 'viewrestrictedlogs' => [ 'suppressionlog' => true, 'deferredblock' => true, ], 'delete' => [ 'edit' => true, 'minoredit' => true, 'applychangetags' => true, 'changetags' => true, 'editcontentmodel' => true, 'createwithcontentmodel' => true, 'browsearchive' => true, 'deletedhistory' => true, 'deletedtext' => true, 'delete' => true, 'bigdelete' => true, 'deletelogentry' => true, 'deleterevision' => true, 'undelete' => true, ], 'oversight' => [ 'suppressrevision' => true, 'viewsuppressed' => true, ], 'protect' => [ 'edit' => true, 'minoredit' => true, 'applychangetags' => true, 'changetags' => true, 'editcontentmodel' => true, 'createwithcontentmodel' => true, 'editprotected' => true, 'protect' => true, ], 'viewmywatchlist' => [ 'viewmywatchlist' => true, ], 'editmywatchlist' => [ 'editmywatchlist' => true, ], 'sendemail' => [ 'sendemail' => true, ], 'createaccount' => [ 'createaccount' => true, ], 'privateinfo' => [ 'viewmyprivateinfo' => true, ], 'mergehistory' => [ 'mergehistory' => true, ], 'managesessions' => [ 'logout' => true, ], ], 'GrantPermissionGroups' => [ 'basic' => 'hidden', 'editpage' => 'page-interaction', 'createeditmovepage' => 'page-interaction', 'editprotected' => 'page-interaction', 'patrol' => 'page-interaction', 'uploadfile' => 'file-interaction', 'uploadeditmovefile' => 'file-interaction', 'sendemail' => 'email', 'viewmywatchlist' => 'watchlist-interaction', 'editmywatchlist' => 'watchlist-interaction', 'editmycssjs' => 'customization', 'editmyoptions' => 'customization', 'editinterface' => 'administration', 'editsiteconfig' => 'administration', 'rollback' => 'administration', 'blockusers' => 'administration', 'delete' => 'administration', 'viewdeleted' => 'administration', 'viewrestrictedlogs' => 'administration', 'protect' => 'administration', 'oversight' => 'administration', 'createaccount' => 'administration', 'mergehistory' => 'administration', 'import' => 'administration', 'highvolume' => 'high-volume', 'privateinfo' => 'private-information', 'managesessions' => 'private-information', ], 'GrantRiskGroups' => [ 'basic' => 'low', 'editpage' => 'low', 'createeditmovepage' => 'low', 'editprotected' => 'vandalism', 'patrol' => 'low', 'uploadfile' => 'low', 'uploadeditmovefile' => 'low', 'sendemail' => 'security', 'viewmywatchlist' => 'low', 'editmywatchlist' => 'low', 'editmycssjs' => 'security', 'editmyoptions' => 'security', 'editinterface' => 'vandalism', 'editsiteconfig' => 'security', 'rollback' => 'low', 'blockusers' => 'vandalism', 'delete' => 'vandalism', 'viewdeleted' => 'vandalism', 'viewrestrictedlogs' => 'security', 'protect' => 'vandalism', 'oversight' => 'security', 'createaccount' => 'low', 'mergehistory' => 'vandalism', 'import' => 'security', 'highvolume' => 'low', 'privateinfo' => 'low', 'managesessions' => 'low', ], 'EnableBotPasswords' => true, 'BotPasswordsCluster' => false, 'BotPasswordsDatabase' => false, 'BotPasswordsLimit' => 100, 'SecretKey' => false, 'JwtPrivateKey' => false, 'JwtPublicKey' => false, 'AllowUserJs' => false, 'ReauthenticateForActions' => [ 'edituserjs' => 'edituserjscss', 'editusercss' => 'edituserjscss', 'editsitejs' => 'editsitejscss', 'editsitecss' => 'editsitejscss', ], 'AllowUserCss' => false, 'AllowUserCssPrefs' => true, 'UseSiteJs' => true, 'UseSiteCss' => true, 'BreakFrames' => false, 'EditPageFrameOptions' => 'DENY', 'ApiFrameOptions' => 'DENY', 'CSPHeader' => false, 'CSPReportOnlyHeader' => false, 'CSPUseReportURIDirective' => false, 'CSPFalsePositiveUrls' => [ 'https: 'https: 'https: 'https: 'https: 'https: 'https: 'https: 'https: 'https: 'https: 'https: 'https: 'https: 'chrome-extension' => true, ], 'AllowCrossOrigin' => false, 'RestAllowCrossOriginCookieAuth' => false, 'SessionSecret' => false, 'CookieExpiration' => 2592000, 'ExtendedLoginCookieExpiration' => 15552000, 'SessionCookieJwtExpiration' => 14400, 'CookieDomain' => '', 'CookiePath' => '/', 'CookieSecure' => 'detect', 'CookiePrefix' => false, 'CookieHttpOnly' => true, 'CookieSameSite' => null, 'CacheVaryCookies' => [ ], 'SessionName' => false, 'CookieSetOnAutoblock' => true, 'CookieSetOnIpBlock' => true, 'DeviceBoundSessions' => false, 'DeviceBoundSessionsReportOnly' => true, 'DeviceBoundSessionCookieName' => '__Host-dbsc', 'DeviceBoundSessionCredentialTTL' => 600, 'DeviceBoundSessionChallengeTTL' => 900, 'DeviceBoundSessionBindingTTL' => 2592000, 'DeviceBoundSessionScopeExcludes' => [ ], 'DebugLogFile' => '', 'DebugLogPrefix' => '', 'DebugRedirects' => false, 'DebugRawPage' => false, 'DebugComments' => false, 'DebugDumpSql' => false, 'TrxProfilerLimits' => [ 'GET' => [ 'masterConns' => 0, 'writes' => 0, 'readQueryTime' => 5, 'readQueryRows' => 10000, ], 'POST' => [ 'readQueryTime' => 5, 'writeQueryTime' => 1, 'readQueryRows' => 100000, 'maxAffected' => 1000, ], 'POST-nonwrite' => [ 'writes' => 0, 'readQueryTime' => 5, 'readQueryRows' => 10000, ], 'PostSend-GET' => [ 'readQueryTime' => 5, 'writeQueryTime' => 1, 'readQueryRows' => 10000, 'maxAffected' => 1000, 'masterConns' => 0, 'writes' => 0, ], 'PostSend-POST' => [ 'readQueryTime' => 5, 'writeQueryTime' => 1, 'readQueryRows' => 100000, 'maxAffected' => 1000, ], 'JobRunner' => [ 'readQueryTime' => 30, 'writeQueryTime' => 5, 'readQueryRows' => 100000, 'maxAffected' => 500, ], 'Maintenance' => [ 'writeQueryTime' => 5, 'maxAffected' => 1000, ], ], 'DebugLogGroups' => [ ], 'MWLoggerDefaultSpi' => [ 'class' => 'MediaWiki\\Logger\\LegacySpi', ], 'ShowDebug' => false, 'SpecialVersionShowHooks' => false, 'ShowExceptionDetails' => false, 'LogExceptionBacktrace' => true, 'PropagateErrors' => true, 'ShowHostnames' => false, 'OverrideHostname' => false, 'DevelopmentWarnings' => false, 'DeprecationReleaseLimit' => false, 'Profiler' => [ ], 'StatsTarget' => null, 'StatsFormat' => null, 'StatsPrefix' => 'mediawiki', 'OpenTelemetryConfig' => null, 'PageInfoTransclusionLimit' => 50, 'EnableJavaScriptTest' => false, 'DebugToolbar' => false, 'ApiClientErrorSampleRate' => 1.0, 'DisableTextSearch' => false, 'AdvancedSearchHighlighting' => false, 'SearchHighlightBoundaries' => '[\\p{Z}\\p{P}\\p{C}]', 'OpenSearchTemplates' => [ 'application/x-suggestions+json' => false, 'application/x-suggestions+xml' => false, ], 'OpenSearchDefaultLimit' => 10, 'OpenSearchDescriptionLength' => 100, 'SearchSuggestCacheExpiry' => 1200, 'DisableSearchUpdate' => false, 'NamespacesToBeSearchedDefault' => [ true, ], 'DisableInternalSearch' => false, 'SearchForwardUrl' => null, 'SitemapNamespaces' => false, 'SitemapNamespacesPriorities' => false, 'SitemapApiConfig' => [ ], 'SpecialSearchFormOptions' => [ ], 'SearchMatchRedirectPreference' => false, 'SearchRunSuggestedQuery' => true, 'Diff3' => '/usr/bin/diff3', 'Diff' => '/usr/bin/diff', 'PreviewOnOpenNamespaces' => [ 14 => true, ], 'UniversalEditButton' => true, 'UseAutomaticEditSummaries' => true, 'CommandLineDarkBg' => false, 'ReadOnly' => null, 'ReadOnlyWatchedItemStore' => false, 'ReadOnlyFile' => false, 'UpgradeKey' => false, 'GitBin' => '/usr/bin/git', 'GitRepositoryViewers' => [ 'https: 'ssh: 'https: 'git@github\\.com:(.*?)(\\.git)?' => 'https: ], 'InstallerInitialPages' => [ [ 'titlemsg' => 'mainpage', 'text' => '{{subst:int:mainpagetext}}{{subst:int:mainpagedocfooter}}', ], ], 'RCMaxAge' => 7776000, 'WatchersMaxAge' => 15552000, 'UnwatchedPageSecret' => 1, 'RCFilterByAge' => false, 'RCLinkLimits' => [ 50, 100, 250, 500, ], 'RCLinkDays' => [ 1, 3, 7, 14, 30, ], 'RCFeeds' => [ ], 'RCWatchCategoryMembership' => false, 'UseRCPatrol' => true, 'StructuredChangeFiltersLiveUpdatePollingRate' => 3, 'UseNPPatrol' => true, 'UseFilePatrol' => true, 'Feed' => true, 'FeedLimit' => 50, 'FeedCacheTimeout' => 60, 'FeedDiffCutoff' => 32768, 'OverrideSiteFeed' => [ ], 'FeedClasses' => [ 'rss' => 'MediaWiki\\Feed\\RSSFeed', 'atom' => 'MediaWiki\\Feed\\AtomFeed', ], 'AdvertisedFeedTypes' => [ 'atom', ], 'RCShowWatchingUsers' => false, 'RCShowChangedSize' => true, 'RCChangedSizeThreshold' => 500, 'ShowUpdatedMarker' => true, 'DisableAnonTalk' => false, 'UseTagFilter' => true, 'SoftwareTags' => [ 'mw-contentmodelchange' => true, 'mw-new-redirect' => true, 'mw-removed-redirect' => true, 'mw-changed-redirect-target' => true, 'mw-blank' => true, 'mw-replace' => true, 'mw-recreated' => true, 'mw-rollback' => true, 'mw-undo' => true, 'mw-manual-revert' => true, 'mw-reverted' => true, 'mw-server-side-upload' => true, 'mw-ipblock-appeal' => true, 'mw-edited-other-users-js' => true, 'mw-edited-other-users-css' => true, ], 'RestrictedTagViewRights' => [ ], 'UnwatchedPageThreshold' => false, 'RecentChangesFlags' => [ 'newpage' => [ 'letter' => 'newpageletter', 'title' => 'recentchanges-label-newpage', 'legend' => 'recentchanges-legend-newpage', 'grouping' => 'any', ], 'minor' => [ 'letter' => 'minoreditletter', 'title' => 'recentchanges-label-minor', 'legend' => 'recentchanges-legend-minor', 'class' => 'minoredit', 'grouping' => 'all', ], 'bot' => [ 'letter' => 'boteditletter', 'title' => 'recentchanges-label-bot', 'legend' => 'recentchanges-legend-bot', 'class' => 'botedit', 'grouping' => 'all', ], 'unpatrolled' => [ 'letter' => 'unpatrolledletter', 'title' => 'recentchanges-label-unpatrolled', 'legend' => 'recentchanges-legend-unpatrolled', 'grouping' => 'any', ], ], 'WatchlistExpiry' => false, 'EnableWatchstarPopover' => false, 'EnableWatchlistLabels' => false, 'WatchlistLabelsMaxPerUser' => 100, 'WatchlistPurgeRate' => 0.1, 'WatchlistExpiryMaxDuration' => '1 year', 'EnableChangesListQueryPartitioning' => false, 'RightsPage' => null, 'RightsUrl' => null, 'RightsText' => null, 'RightsIcon' => null, 'UseCopyrightUpload' => false, 'MaxCredits' => 0, 'ShowCreditsIfMax' => true, 'ImportSources' => [ ], 'ImportTargetNamespace' => null, 'ExportAllowHistory' => true, 'ExportMaxHistory' => 0, 'ExportAllowListContributors' => false, 'ExportMaxLinkDepth' => 0, 'ExportFromNamespaces' => false, 'ExportAllowAll' => false, 'ExportPagelistLimit' => 5000, 'XmlDumpSchemaVersion' => '0.11', 'WikiFarmSettingsDirectory' => null, 'WikiFarmSettingsExtension' => 'yaml', 'ExtensionFunctions' => [ ], 'ExtensionMessagesFiles' => [ ], 'MessagesDirs' => [ ], 'TranslationAliasesDirs' => [ ], 'ExtensionEntryPointListFiles' => [ ], 'EnableParserLimitReporting' => true, 'ValidSkinNames' => [ ], 'SpecialPages' => [ ], 'ExtensionCredits' => [ ], 'Hooks' => [ ], 'ServiceWiringFiles' => [ ], 'JobClasses' => [ 'deletePage' => 'MediaWiki\\Page\\DeletePageJob', 'refreshLinks' => 'MediaWiki\\JobQueue\\Jobs\\RefreshLinksJob', 'deleteLinks' => 'MediaWiki\\Page\\DeleteLinksJob', 'htmlCacheUpdate' => 'MediaWiki\\JobQueue\\Jobs\\HTMLCacheUpdateJob', 'sendMail' => [ 'class' => 'MediaWiki\\Mail\\EmaillingJob', 'services' => [ 'Emailer', ], ], 'enotifNotify' => [ 'class' => 'MediaWiki\\RecentChanges\\RecentChangeNotifyJob', 'services' => [ 'RecentChangeLookup', ], ], 'fixDoubleRedirect' => [ 'class' => 'MediaWiki\\JobQueue\\Jobs\\DoubleRedirectJob', 'services' => [ 'RevisionLookup', 'MagicWordFactory', 'WikiPageFactory', ], 'needsPage' => true, ], 'AssembleUploadChunks' => 'MediaWiki\\JobQueue\\Jobs\\AssembleUploadChunksJob', 'PublishStashedFile' => 'MediaWiki\\JobQueue\\Jobs\\PublishStashedFileJob', 'ThumbnailRender' => 'MediaWiki\\JobQueue\\Jobs\\ThumbnailRenderJob', 'UploadFromUrl' => 'MediaWiki\\JobQueue\\Jobs\\UploadFromUrlJob', 'recentChangesUpdate' => 'MediaWiki\\RecentChanges\\RecentChangesUpdateJob', 'refreshLinksPrioritized' => 'MediaWiki\\JobQueue\\Jobs\\RefreshLinksJob', 'refreshLinksDynamic' => 'MediaWiki\\JobQueue\\Jobs\\RefreshLinksJob', 'activityUpdateJob' => 'MediaWiki\\Watchlist\\ActivityUpdateJob', 'categoryMembershipChange' => [ 'class' => 'MediaWiki\\RecentChanges\\CategoryMembershipChangeJob', 'services' => [ 'RecentChangeFactory', ], ], 'CategoryCountUpdateJob' => [ 'class' => 'MediaWiki\\JobQueue\\Jobs\\CategoryCountUpdateJob', 'services' => [ 'ConnectionProvider', 'NamespaceInfo', ], ], 'clearUserWatchlist' => 'MediaWiki\\Watchlist\\ClearUserWatchlistJob', 'watchlistExpiry' => [ 'class' => 'MediaWiki\\Watchlist\\WatchlistExpiryJob', 'needsPage' => false, ], 'cdnPurge' => 'MediaWiki\\JobQueue\\Jobs\\CdnPurgeJob', 'userGroupExpiry' => 'MediaWiki\\User\\UserGroupExpiryJob', 'clearWatchlistNotifications' => 'MediaWiki\\Watchlist\\ClearWatchlistNotificationsJob', 'userOptionsUpdate' => 'MediaWiki\\User\\Options\\UserOptionsUpdateJob', 'revertedTagUpdate' => 'MediaWiki\\JobQueue\\Jobs\\RevertedTagUpdateJob', 'null' => 'MediaWiki\\JobQueue\\Jobs\\NullJob', 'userEditCountInit' => 'MediaWiki\\User\\UserEditCountInitJob', 'renameUserTable' => [ 'class' => 'MediaWiki\\RenameUser\\Job\\RenameUserTableJob', 'services' => [ 'MainConfig', 'DBLoadBalancerFactory', ], ], 'renameUserDerived' => [ 'class' => 'MediaWiki\\RenameUser\\Job\\RenameUserDerivedJob', 'services' => [ 'RenameUserFactory', 'UserFactory', ], ], 'renameUser' => [ 'class' => 'MediaWiki\\RenameUser\\Job\\RenameUserTableJob', 'services' => [ 'MainConfig', 'DBLoadBalancerFactory', ], ], ], 'JobTypesExcludedFromDefaultQueue' => [ 'AssembleUploadChunks', 'PublishStashedFile', 'UploadFromUrl', ], 'JobBackoffThrottling' => [ ], 'JobTypeConf' => [ 'default' => [ 'class' => 'MediaWiki\\JobQueue\\JobQueueDB', 'order' => 'random', 'claimTTL' => 3600, ], ], 'JobQueueIncludeInMaxLagFactor' => false, 'SpecialPageCacheUpdates' => [ 'Statistics' => [ 'MediaWiki\\Deferred\\SiteStatsUpdate', 'cacheUpdate', ], ], 'PagePropLinkInvalidations' => [ 'hiddencat' => 'categorylinks', ], 'CategoryMagicGallery' => true, 'CategoryPagingLimit' => 200, 'CategoryCollation' => 'uppercase', 'TempCategoryCollations' => [ ], 'SortedCategories' => false, 'TrackingCategories' => [ ], 'LogTypes' => [ '', 'block', 'deferredblock', 'protect', 'rights', 'delete', 'upload', 'move', 'import', 'interwiki', 'patrol', 'merge', 'suppress', 'tag', 'managetags', 'contentmodel', 'renameuser', ], 'LogRestrictions' => [ 'suppress' => 'suppressionlog', 'deferredblock' => 'deferredblock', ], 'FilterLogTypes' => [ 'patrol' => true, 'tag' => true, 'newusers' => false, ], 'LogNames' => [ '' => 'all-logs-page', 'block' => 'blocklogpage', 'protect' => 'protectlogpage', 'rights' => 'rightslog', 'delete' => 'dellogpage', 'upload' => 'uploadlogpage', 'move' => 'movelogpage', 'import' => 'importlogpage', 'patrol' => 'patrol-log-page', 'merge' => 'mergelog', 'suppress' => 'suppressionlog', ], 'LogHeaders' => [ '' => 'alllogstext', 'block' => 'blocklogtext', 'delete' => 'dellogpagetext', 'import' => 'importlogpagetext', 'merge' => 'mergelogpagetext', 'move' => 'movelogpagetext', 'patrol' => 'patrol-log-header', 'protect' => 'protectlogtext', 'rights' => 'rightslogtext', 'suppress' => 'suppressionlogtext', 'upload' => 'uploadlogpagetext', ], 'LogActions' => [ ], 'LogActionsHandlers' => [ 'block/block' => [ 'class' => 'MediaWiki\\Logging\\BlockLogFormatter', 'services' => [ 'TitleParser', 'NamespaceInfo', ], ], 'block/reblock' => [ 'class' => 'MediaWiki\\Logging\\BlockLogFormatter', 'services' => [ 'TitleParser', 'NamespaceInfo', ], ], 'block/unblock' => [ 'class' => 'MediaWiki\\Logging\\BlockLogFormatter', 'services' => [ 'TitleParser', 'NamespaceInfo', ], ], 'contentmodel/change' => 'MediaWiki\\Logging\\ContentModelLogFormatter', 'contentmodel/new' => 'MediaWiki\\Logging\\ContentModelLogFormatter', 'deferredblock/block' => [ 'class' => 'MediaWiki\\Logging\\BlockLogFormatter', 'services' => [ 'TitleParser', 'NamespaceInfo', ], ], 'deferredblock/reblock' => [ 'class' => 'MediaWiki\\Logging\\BlockLogFormatter', 'services' => [ 'TitleParser', 'NamespaceInfo', ], ], 'deferredblock/unblock' => [ 'class' => 'MediaWiki\\Logging\\BlockLogFormatter', 'services' => [ 'TitleParser', 'NamespaceInfo', ], ], 'delete/delete' => 'MediaWiki\\Logging\\DeleteLogFormatter', 'delete/delete_redir' => 'MediaWiki\\Logging\\DeleteLogFormatter', 'delete/delete_redir2' => 'MediaWiki\\Logging\\DeleteLogFormatter', 'delete/event' => 'MediaWiki\\Logging\\DeleteLogFormatter', 'delete/restore' => 'MediaWiki\\Logging\\DeleteLogFormatter', 'delete/revision' => 'MediaWiki\\Logging\\DeleteLogFormatter', 'import/interwiki' => 'MediaWiki\\Logging\\ImportLogFormatter', 'import/upload' => 'MediaWiki\\Logging\\ImportLogFormatter', 'interwiki/iw_add' => 'MediaWiki\\Logging\\InterwikiLogFormatter', 'interwiki/iw_delete' => 'MediaWiki\\Logging\\InterwikiLogFormatter', 'interwiki/iw_edit' => 'MediaWiki\\Logging\\InterwikiLogFormatter', 'managetags/activate' => 'MediaWiki\\Logging\\LogFormatter', 'managetags/create' => 'MediaWiki\\Logging\\LogFormatter', 'managetags/deactivate' => 'MediaWiki\\Logging\\LogFormatter', 'managetags/delete' => 'MediaWiki\\Logging\\LogFormatter', 'merge/merge' => [ 'class' => 'MediaWiki\\Logging\\MergeLogFormatter', 'services' => [ 'TitleParser', ], ], 'merge/merge-into' => [ 'class' => 'MediaWiki\\Logging\\MergeLogFormatter', 'services' => [ 'TitleParser', ], ], 'move/move' => [ 'class' => 'MediaWiki\\Logging\\MoveLogFormatter', 'services' => [ 'TitleParser', ], ], 'move/move_redir' => [ 'class' => 'MediaWiki\\Logging\\MoveLogFormatter', 'services' => [ 'TitleParser', ], ], 'patrol/patrol' => 'MediaWiki\\Logging\\PatrolLogFormatter', 'patrol/autopatrol' => 'MediaWiki\\Logging\\PatrolLogFormatter', 'protect/modify' => [ 'class' => 'MediaWiki\\Logging\\ProtectLogFormatter', 'services' => [ 'TitleParser', ], ], 'protect/move_prot' => [ 'class' => 'MediaWiki\\Logging\\ProtectLogFormatter', 'services' => [ 'TitleParser', ], ], 'protect/protect' => [ 'class' => 'MediaWiki\\Logging\\ProtectLogFormatter', 'services' => [ 'TitleParser', ], ], 'protect/unprotect' => [ 'class' => 'MediaWiki\\Logging\\ProtectLogFormatter', 'services' => [ 'TitleParser', ], ], 'renameuser/renameuser' => [ 'class' => 'MediaWiki\\Logging\\RenameuserLogFormatter', 'services' => [ 'TitleParser', ], ], 'rights/autopromote' => 'MediaWiki\\Logging\\RightsLogFormatter', 'rights/rights' => 'MediaWiki\\Logging\\RightsLogFormatter', 'suppress/block' => [ 'class' => 'MediaWiki\\Logging\\BlockLogFormatter', 'services' => [ 'TitleParser', 'NamespaceInfo', ], ], 'suppress/delete' => 'MediaWiki\\Logging\\DeleteLogFormatter', 'suppress/event' => 'MediaWiki\\Logging\\DeleteLogFormatter', 'suppress/reblock' => [ 'class' => 'MediaWiki\\Logging\\BlockLogFormatter', 'services' => [ 'TitleParser', 'NamespaceInfo', ], ], 'suppress/revision' => 'MediaWiki\\Logging\\DeleteLogFormatter', 'suppress/unblock' => [ 'class' => 'MediaWiki\\Logging\\BlockLogFormatter', 'services' => [ 'TitleParser', 'NamespaceInfo', ], ], 'tag/update' => 'MediaWiki\\Logging\\TagLogFormatter', 'upload/overwrite' => 'MediaWiki\\Logging\\UploadLogFormatter', 'upload/revert' => 'MediaWiki\\Logging\\UploadLogFormatter', 'upload/upload' => 'MediaWiki\\Logging\\UploadLogFormatter', ], 'ActionFilteredLogs' => [ 'block' => [ 'block' => [ 'block', ], 'reblock' => [ 'reblock', ], 'unblock' => [ 'unblock', ], ], 'contentmodel' => [ 'change' => [ 'change', ], 'new' => [ 'new', ], ], 'deferredblock' => [ 'block' => [ 'block', ], 'reblock' => [ 'reblock', ], 'unblock' => [ 'unblock', ], ], 'delete' => [ 'delete' => [ 'delete', ], 'delete_redir' => [ 'delete_redir', 'delete_redir2', ], 'restore' => [ 'restore', ], 'event' => [ 'event', ], 'revision' => [ 'revision', ], ], 'import' => [ 'interwiki' => [ 'interwiki', ], 'upload' => [ 'upload', ], ], 'managetags' => [ 'create' => [ 'create', ], 'delete' => [ 'delete', ], 'activate' => [ 'activate', ], 'deactivate' => [ 'deactivate', ], ], 'move' => [ 'move' => [ 'move', ], 'move_redir' => [ 'move_redir', ], ], 'newusers' => [ 'create' => [ 'create', 'newusers', ], 'create2' => [ 'create2', ], 'autocreate' => [ 'autocreate', ], 'byemail' => [ 'byemail', ], ], 'protect' => [ 'protect' => [ 'protect', ], 'modify' => [ 'modify', ], 'unprotect' => [ 'unprotect', ], 'move_prot' => [ 'move_prot', ], ], 'rights' => [ 'rights' => [ 'rights', ], 'autopromote' => [ 'autopromote', ], ], 'suppress' => [ 'event' => [ 'event', ], 'revision' => [ 'revision', ], 'delete' => [ 'delete', ], 'block' => [ 'block', ], 'reblock' => [ 'reblock', ], 'unblock' => [ 'unblock', ], ], 'upload' => [ 'upload' => [ 'upload', ], 'overwrite' => [ 'overwrite', ], 'revert' => [ 'revert', ], ], ], 'NewUserLog' => true, 'WatchUserPageOnAccountCreation' => true, 'PageCreationLog' => true, 'AllowSpecialInclusion' => true, 'DisableQueryPageUpdate' => false, 'CountCategorizedImagesAsUsed' => false, 'MaxRedirectLinksRetrieved' => 500, 'RangeContributionsCIDRLimit' => [ 'IPv4' => 16, 'IPv6' => 32, ], 'Actions' => [ ], 'DefaultRobotPolicy' => 'index,follow', 'NamespaceRobotPolicies' => [ ], 'ArticleRobotPolicies' => [ ], 'ExemptFromUserRobotsControl' => null, 'DebugAPI' => false, 'APIModules' => [ ], 'APIFormatModules' => [ ], 'APIMetaModules' => [ ], 'APIPropModules' => [ ], 'APIListModules' => [ ], 'APIMaxDBRows' => 5000, 'APIMaxResultSize' => 8388608, 'APIMaxUncachedDiffs' => 1, 'APIMaxLagThreshold' => 7, 'APICacheHelpTimeout' => 3600, 'APIUselessQueryPages' => [ 'MIMEsearch', 'LinkSearch', ], 'AjaxLicensePreview' => true, 'CrossSiteAJAXdomains' => [ ], 'CrossSiteAJAXdomainExceptions' => [ ], 'AllowedCorsHeaders' => [ 'Accept', 'Accept-Language', 'Content-Language', 'Content-Type', 'Accept-Encoding', 'DNT', 'Origin', 'User-Agent', 'Api-User-Agent', 'Promise-Non-Write-API-Action', 'Access-Control-Max-Age', 'Authorization', ], 'RestAPIAdditionalRouteFiles' => [ ], 'RestLocalModuleTestBaseUrl' => null, 'RestModuleOverrides' => [ ], 'RestExternalModules' => [ ], 'RestTermsOfServiceUrl' => null, 'MaxShellMemory' => 307200, 'MaxShellFileSize' => 102400, 'MaxShellTime' => 180, 'MaxShellWallClockTime' => 180, 'ShellCgroup' => false, 'PhpCli' => '/usr/bin/php', 'ShellRestrictionMethod' => 'autodetect', 'ShellboxUrls' => [ 'default' => null, ], 'ShellboxSecretKey' => null, 'ShellboxShell' => '/bin/sh', 'HTTPTimeout' => 25, 'HTTPConnectTimeout' => 5.0, 'HTTPMaxTimeout' => 0, 'HTTPMaxConnectTimeout' => 0, 'HTTPImportTimeout' => 25, 'HTTPUserAgentContact' => false, 'AsyncHTTPTimeout' => 25, 'HTTPProxy' => '', 'LocalVirtualHosts' => [ ], 'LocalHTTPProxy' => false, 'AllowExternalReqID' => false, 'GenerateReqIDFormat' => 'rand24', 'JobRunRate' => 1, 'RunJobsAsync' => false, 'UpdateRowsPerJob' => 300, 'UpdateRowsPerQuery' => 100, 'RedirectOnLogin' => null, 'EventRelayerConfig' => [ 'default' => [ 'class' => 'Wikimedia\\EventRelayer\\EventRelayerNull', ], ], 'Pingback' => false, 'OriginTrials' => [ ], 'ReportToExpiry' => 86400, 'ReportToEndpoints' => [ ], 'FeaturePolicyReportOnly' => [ ], 'SkinsPreferred' => [ 'vector-2022', 'vector', ], 'SpecialContributeSkinsEnabled' => [ ], 'SpecialContributeNewPageTarget' => null, 'EnableEditRecovery' => false, 'EditRecoveryExpiry' => 2592000, 'UseCodexSpecialBlock' => false, 'ShowLogoutConfirmation' => false, 'EnableProtectionIndicators' => true, 'OutputPipelineStages' => [ ], 'FeatureShutdown' => [ ], 'UseLeximorph' => false, 'UsePostprocCacheLegacy' => false, 'UsePostprocCacheParsoid' => true, 'ParserOptionsLogUnsafeSampleRate' => 0, 'ReturnExperimentalPFragmentTypes' => [ ], 'UseParsoidLinksUpdate' => null, 'UseParsoidMessages' => false, 'UseParsoidParser' => true, 'SiteLookup' => [ ], ], 'type' => [ 'ConfigRegistry' => 'object', 'AssumeProxiesUseDefaultProtocolPorts' => 'boolean', 'ForceHTTPS' => 'boolean', 'ExtensionDirectory' => [ 'string', 'null', ], 'StyleDirectory' => [ 'string', 'null', ], 'UploadDirectory' => [ 'string', 'boolean', 'null', ], 'Logos' => [ 'object', 'boolean', ], 'ReferrerPolicy' => [ 'array', 'string', 'boolean', ], 'ActionPaths' => 'object', 'MainPageIsDomainRoot' => 'boolean', 'ImgAuthUrlPathMap' => 'object', 'LocalFileRepo' => 'object', 'ForeignFileRepos' => 'array', 'UseSharedUploads' => 'boolean', 'SharedUploadDirectory' => [ 'string', 'null', ], 'SharedUploadPath' => [ 'string', 'null', ], 'HashedSharedUploadDirectory' => 'boolean', 'FetchCommonsDescriptions' => 'boolean', 'SharedUploadDBname' => [ 'boolean', 'string', ], 'SharedUploadDBprefix' => 'string', 'SharedUploadDBschema' => [ 'string', 'null', ], 'CacheSharedUploads' => 'boolean', 'ForeignUploadTargets' => 'array', 'UploadDialog' => 'object', 'FileBackends' => 'object', 'LockManagers' => 'array', 'DefaultLockManager' => [ 'string', 'null', ], 'CopyUploadsDomains' => 'array', 'CopyUploadTimeout' => [ 'boolean', 'integer', ], 'SharedThumbnailScriptPath' => [ 'string', 'boolean', ], 'HashedUploadDirectory' => 'boolean', 'CSPUploadEntryPoint' => 'boolean', 'FileExtensions' => 'array', 'ProhibitedFileExtensions' => 'array', 'MimeTypeExclusions' => 'array', 'TrustedMediaFormats' => 'array', 'MediaHandlers' => 'object', 'NativeImageLazyLoading' => 'boolean', 'ParserTestMediaHandlers' => 'object', 'MaxInterlacingAreas' => 'object', 'SVGConverters' => 'object', 'SVGNativeRendering' => [ 'string', 'boolean', ], 'MaxImageArea' => [ 'string', 'integer', 'boolean', ], 'TiffThumbnailType' => 'array', 'GenerateThumbnailOnParse' => 'boolean', 'EnableAutoRotation' => [ 'boolean', 'null', ], 'Antivirus' => [ 'string', 'null', ], 'AntivirusSetup' => 'object', 'MimeDetectorCommand' => [ 'string', 'null', ], 'XMLMimeTypes' => 'object', 'ImageLimits' => 'array', 'ThumbLimits' => 'array', 'ThumbnailNamespaces' => 'array', 'ThumbnailSteps' => [ 'array', 'null', ], 'ThumbnailBuckets' => [ 'array', 'null', ], 'UploadThumbnailRenderMap' => 'object', 'GalleryOptions' => 'object', 'DjvuDump' => [ 'string', 'null', ], 'DjvuRenderer' => [ 'string', 'null', ], 'DjvuTxt' => [ 'string', 'null', ], 'DjvuPostProcessor' => [ 'string', 'null', ], 'SMTP' => [ 'boolean', 'object', ], 'EnotifFromEditor' => 'boolean', 'EmailConfirmationBanner' => 'boolean', 'EnotifRevealEditorAddress' => 'boolean', 'UsersNotifiedOnAllChanges' => 'object', 'DBmwschema' => [ 'string', 'null', ], 'SharedTables' => 'array', 'DBservers' => [ 'boolean', 'array', ], 'LBFactoryConf' => 'object', 'LocalDatabases' => 'array', 'VirtualDomainsMapping' => 'object', 'RemoteVirtualDomainsMapping' => 'object', 'FileSchemaMigrationStage' => 'integer', 'ExternalLinksDomainGaps' => 'object', 'ContentHandlers' => 'object', 'NamespaceContentModels' => 'object', 'TextModelsToParse' => 'array', 'ExternalStores' => 'array', 'ExternalServers' => 'object', 'DefaultExternalStore' => [ 'array', 'boolean', ], 'RevisionCacheExpiry' => 'integer', 'PageLanguageUseDB' => 'boolean', 'DiffEngine' => [ 'string', 'null', ], 'ExternalDiffEngine' => [ 'string', 'boolean', ], 'Wikidiff2Options' => 'object', 'RequestTimeLimit' => [ 'integer', 'null', ], 'CriticalSectionTimeLimit' => 'number', 'PoolCounterConf' => [ 'object', 'null', ], 'PoolCountClientConf' => 'object', 'MaxUserDBWriteDuration' => [ 'integer', 'boolean', ], 'MaxJobDBWriteDuration' => [ 'integer', 'boolean', ], 'MultiShardSiteStats' => 'boolean', 'ObjectCaches' => 'object', 'WANObjectCache' => 'object', 'MicroStashType' => [ 'string', 'integer', ], 'ParsoidCacheConfig' => 'object', 'ParsoidSelectiveUpdateSampleRate' => 'integer', 'SplitParsoidParserCache' => 'boolean', 'ParserCacheFilterConfig' => 'object', 'ChronologyProtectorSecret' => 'string', 'SuspiciousIpExpiry' => [ 'integer', 'boolean', ], 'MemCachedServers' => 'array', 'LocalisationCacheConf' => 'object', 'ExtensionInfoMTime' => [ 'integer', 'boolean', ], 'CdnServers' => 'object', 'CdnServersNoPurge' => 'object', 'HTCPRouting' => 'object', 'GrammarForms' => 'object', 'ExtraInterlanguageLinkPrefixes' => 'array', 'InterlanguageLinkCodeMap' => 'object', 'ExtraLanguageNames' => 'object', 'ExtraLanguageCodes' => 'object', 'DummyLanguageCodes' => 'object', 'DisabledVariants' => 'object', 'ForceUIMsgAsContentMsg' => 'object', 'RawHtmlMessages' => 'array', 'OverrideUcfirstCharacters' => 'object', 'XhtmlNamespaces' => 'object', 'BrowserFormatDetection' => 'string', 'SkinMetaTags' => 'object', 'SkipSkins' => 'object', 'FragmentMode' => 'array', 'FooterIcons' => 'object', 'PageShareSkinsEnabled' => 'array', 'InterwikiLogoOverride' => 'array', 'ResourceModules' => 'object', 'ResourceModuleSkinStyles' => 'object', 'ResourceLoaderSources' => 'object', 'ResourceLoaderMaxage' => 'object', 'ResourceLoaderMaxQueryLength' => [ 'integer', 'boolean', ], 'CanonicalNamespaceNames' => 'object', 'ExtraNamespaces' => 'object', 'ExtraGenderNamespaces' => 'object', 'NamespaceAliases' => 'object', 'CapitalLinkOverrides' => 'object', 'NamespacesWithSubpages' => 'object', 'NamespacesWithoutAutoSummaries' => 'array', 'ContentNamespaces' => 'array', 'ShortPagesNamespaceExclusions' => 'array', 'ExtraSignatureNamespaces' => 'array', 'InvalidRedirectTargets' => 'array', 'LocalInterwikis' => 'array', 'InterwikiCache' => [ 'boolean', 'object', ], 'SiteTypes' => 'object', 'UrlProtocols' => 'array', 'TidyConfig' => 'object', 'ParsoidSettings' => 'object', 'ParsoidExperimentalParserFunctionOutput' => 'boolean', 'NoFollowNsExceptions' => 'array', 'NoFollowDomainExceptions' => 'array', 'ExternalLinksIgnoreDomains' => 'array', 'EnableMagicLinks' => 'object', 'ManualRevertSearchRadius' => 'integer', 'RevertedTagMaxDepth' => 'integer', 'CentralIdLookupProviders' => 'object', 'CentralIdLookupProvider' => 'string', 'UserRegistrationProviders' => 'object', 'PasswordPolicy' => 'object', 'AuthManagerConfig' => [ 'object', 'null', ], 'AuthManagerAutoConfig' => 'object', 'RememberMe' => 'string', 'ReauthenticateTime' => 'object', 'ChangeCredentialsBlacklist' => 'array', 'RemoveCredentialsBlacklist' => 'array', 'PasswordConfig' => 'object', 'PasswordResetRoutes' => 'object', 'SignatureAllowedLintErrors' => 'array', 'ReservedUsernames' => 'array', 'DefaultUserOptions' => 'object', 'ConditionalUserOptions' => 'object', 'HiddenPrefs' => 'array', 'UserJsPrefLimit' => 'integer', 'AuthenticationTokenVersion' => [ 'string', 'null', ], 'SessionProviders' => 'object', 'AutoCreateTempUser' => 'object', 'AutoblockExemptions' => 'array', 'BlockCIDRLimit' => 'object', 'EnableMultiBlocks' => 'boolean', 'GroupPermissions' => 'object', 'PrivilegedGroups' => 'array', 'RevokePermissions' => 'object', 'GroupInheritsPermissions' => 'object', 'ImplicitGroups' => 'array', 'GroupsAddToSelf' => 'object', 'GroupsRemoveFromSelf' => 'object', 'RestrictedGroups' => 'object', 'UserRequirementsPrivateConditions' => 'array', 'RestrictionTypes' => 'array', 'RestrictionLevels' => 'array', 'CascadingRestrictionLevels' => 'array', 'SemiprotectedRestrictionLevels' => 'array', 'NamespaceProtection' => 'object', 'RestrictUserPageEditing' => 'boolean', 'NonincludableNamespaces' => 'object', 'Autopromote' => 'object', 'AutopromoteOnce' => 'object', 'AutopromoteOnceRCExcludedGroups' => 'array', 'AddGroups' => 'object', 'RemoveGroups' => 'object', 'AvailableRights' => 'array', 'ImplicitRights' => 'array', 'AccountCreationThrottle' => [ 'integer', 'array', ], 'TempAccountCreationThrottle' => 'array', 'TempAccountNameAcquisitionThrottle' => 'array', 'SpamRegex' => 'array', 'SummarySpamRegex' => 'array', 'DnsBlacklistUrls' => 'array', 'ProxyList' => [ 'string', 'array', ], 'ProxyWhitelist' => 'array', 'SoftBlockRanges' => 'array', 'RateLimits' => 'object', 'RateLimitsExcludedIPs' => 'array', 'ExternalQuerySources' => 'object', 'PasswordAttemptThrottle' => 'array', 'GrantPermissions' => 'object', 'GrantPermissionGroups' => 'object', 'GrantRiskGroups' => 'object', 'EnableBotPasswords' => 'boolean', 'BotPasswordsCluster' => [ 'string', 'boolean', ], 'BotPasswordsDatabase' => [ 'string', 'boolean', ], 'BotPasswordsLimit' => 'integer', 'ReauthenticateForActions' => 'object', 'CSPHeader' => [ 'boolean', 'object', ], 'CSPReportOnlyHeader' => [ 'boolean', 'object', ], 'CSPUseReportURIDirective' => [ 'boolean', 'object', ], 'CSPFalsePositiveUrls' => 'object', 'AllowCrossOrigin' => 'boolean', 'RestAllowCrossOriginCookieAuth' => 'boolean', 'CookieSameSite' => [ 'string', 'null', ], 'CacheVaryCookies' => 'array', 'DeviceBoundSessions' => 'boolean', 'DeviceBoundSessionsReportOnly' => 'boolean', 'DeviceBoundSessionCookieName' => 'string', 'DeviceBoundSessionCredentialTTL' => 'integer', 'DeviceBoundSessionChallengeTTL' => 'integer', 'DeviceBoundSessionBindingTTL' => 'integer', 'DeviceBoundSessionScopeExcludes' => 'array', 'TrxProfilerLimits' => 'object', 'DebugLogGroups' => 'object', 'MWLoggerDefaultSpi' => 'object', 'Profiler' => 'object', 'StatsTarget' => [ 'string', 'null', ], 'StatsFormat' => [ 'string', 'null', ], 'StatsPrefix' => 'string', 'OpenTelemetryConfig' => [ 'object', 'null', ], 'OpenSearchTemplates' => 'object', 'NamespacesToBeSearchedDefault' => 'object', 'SitemapNamespaces' => [ 'boolean', 'array', ], 'SitemapNamespacesPriorities' => [ 'boolean', 'object', ], 'SitemapApiConfig' => 'object', 'SpecialSearchFormOptions' => 'object', 'SearchMatchRedirectPreference' => 'boolean', 'SearchRunSuggestedQuery' => 'boolean', 'PreviewOnOpenNamespaces' => 'object', 'ReadOnlyWatchedItemStore' => 'boolean', 'GitRepositoryViewers' => 'object', 'InstallerInitialPages' => 'array', 'RCLinkLimits' => 'array', 'RCLinkDays' => 'array', 'RCFeeds' => 'object', 'OverrideSiteFeed' => 'object', 'FeedClasses' => 'object', 'AdvertisedFeedTypes' => 'array', 'SoftwareTags' => 'object', 'RestrictedTagViewRights' => 'object', 'RecentChangesFlags' => 'object', 'WatchlistExpiry' => 'boolean', 'EnableWatchstarPopover' => 'boolean', 'EnableWatchlistLabels' => 'boolean', 'WatchlistLabelsMaxPerUser' => 'integer', 'WatchlistPurgeRate' => 'number', 'WatchlistExpiryMaxDuration' => [ 'string', 'null', ], 'EnableChangesListQueryPartitioning' => 'boolean', 'ImportSources' => 'object', 'ExtensionFunctions' => 'array', 'ExtensionMessagesFiles' => 'object', 'MessagesDirs' => 'object', 'TranslationAliasesDirs' => 'object', 'ExtensionEntryPointListFiles' => 'object', 'ValidSkinNames' => 'object', 'SpecialPages' => 'object', 'ExtensionCredits' => 'object', 'Hooks' => 'object', 'ServiceWiringFiles' => 'array', 'JobClasses' => 'object', 'JobTypesExcludedFromDefaultQueue' => 'array', 'JobBackoffThrottling' => 'object', 'JobTypeConf' => 'object', 'SpecialPageCacheUpdates' => 'object', 'PagePropLinkInvalidations' => 'object', 'TempCategoryCollations' => 'array', 'SortedCategories' => 'boolean', 'TrackingCategories' => 'array', 'LogTypes' => 'array', 'LogRestrictions' => 'object', 'FilterLogTypes' => 'object', 'LogNames' => 'object', 'LogHeaders' => 'object', 'LogActions' => 'object', 'LogActionsHandlers' => 'object', 'ActionFilteredLogs' => 'object', 'WatchUserPageOnAccountCreation' => 'boolean', 'RangeContributionsCIDRLimit' => 'object', 'Actions' => 'object', 'NamespaceRobotPolicies' => 'object', 'ArticleRobotPolicies' => 'object', 'ExemptFromUserRobotsControl' => [ 'array', 'null', ], 'APIModules' => 'object', 'APIFormatModules' => 'object', 'APIMetaModules' => 'object', 'APIPropModules' => 'object', 'APIListModules' => 'object', 'APIUselessQueryPages' => 'array', 'CrossSiteAJAXdomains' => 'object', 'CrossSiteAJAXdomainExceptions' => 'object', 'AllowedCorsHeaders' => 'array', 'RestAPIAdditionalRouteFiles' => 'array', 'RestLocalModuleTestBaseUrl' => [ 'string', 'null', ], 'RestModuleOverrides' => 'object', 'RestExternalModules' => 'object', 'RestTermsOfServiceUrl' => [ 'string', 'null', ], 'ShellRestrictionMethod' => [ 'string', 'boolean', ], 'ShellboxUrls' => 'object', 'ShellboxSecretKey' => [ 'string', 'null', ], 'ShellboxShell' => [ 'string', 'null', ], 'HTTPTimeout' => 'number', 'HTTPConnectTimeout' => 'number', 'HTTPMaxTimeout' => 'number', 'HTTPMaxConnectTimeout' => 'number', 'HTTPUserAgentContact' => [ 'string', 'boolean', ], 'LocalVirtualHosts' => 'object', 'LocalHTTPProxy' => [ 'string', 'boolean', ], 'GenerateReqIDFormat' => 'string', 'EventRelayerConfig' => 'object', 'Pingback' => 'boolean', 'OriginTrials' => 'array', 'ReportToExpiry' => 'integer', 'ReportToEndpoints' => 'array', 'FeaturePolicyReportOnly' => 'array', 'SkinsPreferred' => 'array', 'SpecialContributeSkinsEnabled' => 'array', 'SpecialContributeNewPageTarget' => [ 'string', 'null', ], 'EnableEditRecovery' => 'boolean', 'EditRecoveryExpiry' => 'integer', 'UseCodexSpecialBlock' => 'boolean', 'ShowLogoutConfirmation' => 'boolean', 'EnableProtectionIndicators' => 'boolean', 'OutputPipelineStages' => 'object', 'FeatureShutdown' => 'array', 'UseLeximorph' => 'boolean', 'UsePostprocCacheLegacy' => 'boolean', 'UsePostprocCacheParsoid' => 'boolean', 'ParserOptionsLogUnsafeSampleRate' => 'integer', 'ReturnExperimentalPFragmentTypes' => 'array', 'UseParsoidLinksUpdate' => [ 'boolean', 'null', ], 'UseParsoidMessages' => [ 'boolean', 'null', ], 'UseParsoidParser' => 'boolean', 'SiteLookup' => 'object', ], 'mergeStrategy' => [ 'TiffThumbnailType' => 'replace', 'LBFactoryConf' => 'replace', 'InterwikiCache' => 'replace', 'PasswordPolicy' => 'array_replace_recursive', 'AuthManagerAutoConfig' => 'array_plus_2d', 'GroupPermissions' => 'array_plus_2d', 'RevokePermissions' => 'array_plus_2d', 'AddGroups' => 'array_merge_recursive', 'RemoveGroups' => 'array_merge_recursive', 'RateLimits' => 'array_plus_2d', 'GrantPermissions' => 'array_plus_2d', 'MWLoggerDefaultSpi' => 'replace', 'Profiler' => 'replace', 'Hooks' => 'array_merge_recursive', 'RestModuleOverrides' => 'array_replace_recursive', 'RestExternalModules' => 'array_replace_recursive', ], 'dynamicDefault' => [ 'UsePathInfo' => [ 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultUsePathInfo', ], ], 'Script' => [ 'use' => [ 'ScriptPath', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultScript', ], ], 'LoadScript' => [ 'use' => [ 'ScriptPath', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultLoadScript', ], ], 'RestPath' => [ 'use' => [ 'ScriptPath', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultRestPath', ], ], 'StylePath' => [ 'use' => [ 'ResourceBasePath', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultStylePath', ], ], 'LocalStylePath' => [ 'use' => [ 'ScriptPath', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultLocalStylePath', ], ], 'ExtensionAssetsPath' => [ 'use' => [ 'ResourceBasePath', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultExtensionAssetsPath', ], ], 'ArticlePath' => [ 'use' => [ 'Script', 'UsePathInfo', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultArticlePath', ], ], 'UploadPath' => [ 'use' => [ 'ScriptPath', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultUploadPath', ], ], 'FileCacheDirectory' => [ 'use' => [ 'UploadDirectory', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultFileCacheDirectory', ], ], 'Logo' => [ 'use' => [ 'ResourceBasePath', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultLogo', ], ], 'DeletedDirectory' => [ 'use' => [ 'UploadDirectory', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultDeletedDirectory', ], ], 'ShowEXIF' => [ 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultShowEXIF', ], ], 'SharedPrefix' => [ 'use' => [ 'DBprefix', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultSharedPrefix', ], ], 'SharedSchema' => [ 'use' => [ 'DBmwschema', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultSharedSchema', ], ], 'DBerrorLogTZ' => [ 'use' => [ 'Localtimezone', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultDBerrorLogTZ', ], ], 'Localtimezone' => [ 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultLocaltimezone', ], ], 'LocalTZoffset' => [ 'use' => [ 'Localtimezone', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultLocalTZoffset', ], ], 'ResourceBasePath' => [ 'use' => [ 'ScriptPath', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultResourceBasePath', ], ], 'MetaNamespace' => [ 'use' => [ 'Sitename', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultMetaNamespace', ], ], 'CookieSecure' => [ 'use' => [ 'ForceHTTPS', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultCookieSecure', ], ], 'CookiePrefix' => [ 'use' => [ 'SharedDB', 'SharedPrefix', 'SharedTables', 'DBname', 'DBprefix', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultCookiePrefix', ], ], 'ReadOnlyFile' => [ 'use' => [ 'UploadDirectory', ], 'callback' => [ 'MediaWiki\\MainConfigSchema', 'getDefaultReadOnlyFile', ], ], ], ], 'config-schema' => [ 'UploadStashScalerBaseUrl' => [ 'deprecated' => 'since 1.36 Use thumbProxyUrl in $wgLocalFileRepo', ], 'IllegalFileChars' => [ 'deprecated' => 'since 1.41; no longer customizable', ], 'ThumbnailNamespaces' => [ 'items' => [ 'type' => 'integer', ], ], 'LocalDatabases' => [ 'items' => [ 'type' => 'string', ], ], 'ParserCacheFilterConfig' => [ 'additionalProperties' => [ 'type' => 'object', 'description' => 'A map of namespace IDs to filter definitions.', 'additionalProperties' => [ 'type' => 'object', 'description' => 'A map of filter names to values.', 'properties' => [ 'minCpuTime' => [ 'type' => 'number', ], ], ], ], ], 'RawHtmlMessages' => [ 'items' => [ 'type' => 'string', ], ], 'InterwikiLogoOverride' => [ 'items' => [ 'type' => 'string', ], ], 'LegalTitleChars' => [ 'deprecated' => 'since 1.41; use Extension:TitleBlacklist to customize', ], 'ReauthenticateTime' => [ 'additionalProperties' => [ 'type' => [ 'integer', 'array', ], ], ], 'ChangeCredentialsBlacklist' => [ 'items' => [ 'type' => 'string', ], ], 'RemoveCredentialsBlacklist' => [ 'items' => [ 'type' => 'string', ], ], 'GroupPermissions' => [ 'additionalProperties' => [ 'type' => 'object', 'additionalProperties' => [ 'type' => 'boolean', ], ], ], 'GroupInheritsPermissions' => [ 'additionalProperties' => [ 'type' => 'string', ], ], 'AvailableRights' => [ 'items' => [ 'type' => 'string', ], ], 'ImplicitRights' => [ 'items' => [ 'type' => 'string', ], ], 'SoftBlockRanges' => [ 'items' => [ 'type' => 'string', ], ], 'ExternalQuerySources' => [ 'additionalProperties' => [ 'type' => 'object', 'properties' => [ 'enabled' => [ 'type' => 'boolean', 'default' => false, ], 'url' => [ 'type' => 'string', 'format' => 'uri', ], 'timeout' => [ 'type' => 'integer', 'default' => 10, ], ], 'required' => [ 'enabled', 'url', ], 'additionalProperties' => false, ], ], 'GrantPermissions' => [ 'additionalProperties' => [ 'type' => 'object', 'additionalProperties' => [ 'type' => 'boolean', ], ], ], 'GrantPermissionGroups' => [ 'additionalProperties' => [ 'type' => 'string', ], ], 'SitemapNamespacesPriorities' => [ 'deprecated' => 'since 1.45 and ignored', ], 'SitemapApiConfig' => [ 'additionalProperties' => [ 'enabled' => [ 'type' => 'bool', ], 'sitemapsPerIndex' => [ 'type' => 'int', ], 'pagesPerSitemap' => [ 'type' => 'int', ], 'expiry' => [ 'type' => 'int', ], 'skipRedirects' => [ 'type' => 'bool', ], ], ], 'SoftwareTags' => [ 'additionalProperties' => [ 'type' => 'boolean', ], ], 'UseCopyrightUpload' => [ 'deprecated' => 'since 1.47 This feature is being removed.', ], 'JobBackoffThrottling' => [ 'additionalProperties' => [ 'type' => 'number', ], ], 'JobTypeConf' => [ 'additionalProperties' => [ 'type' => 'object', 'properties' => [ 'class' => [ 'type' => 'string', ], 'order' => [ 'type' => 'string', ], 'claimTTL' => [ 'type' => 'integer', ], ], ], ], 'TrackingCategories' => [ 'deprecated' => 'since 1.25 Extensions should now register tracking categories using the new extension registration system.', ], 'RangeContributionsCIDRLimit' => [ 'additionalProperties' => [ 'type' => 'integer', ], ], 'RestModuleOverrides' => [ 'additionalProperties' => [ 'type' => 'object', 'properties' => [ 'availability' => [ 'type' => 'string', ], 'groups' => [ 'type' => 'array', ], ], ], ], 'RestExternalModules' => [ 'additionalProperties' => [ 'type' => 'object', 'properties' => [ 'info' => [ 'type' => 'object', 'properties' => [ 'version' => [ 'type' => 'string', ], 'title' => [ 'type' => 'string', ], 'x-i18n-title' => [ 'type' => 'string', ], 'description' => [ 'type' => 'string', ], 'x-i18n-description' => [ 'type' => 'string', ], ], 'required' => [ 'version', ], ], 'base' => [ 'type' => 'string', 'format' => 'uri', ], 'spec' => [ 'type' => 'string', 'format' => 'uri', ], ], 'required' => [ 'info', 'base', 'spec', ], ], ], 'ShellboxUrls' => [ 'additionalProperties' => [ 'type' => [ 'string', 'boolean', 'null', ], ], ], ], 'obsolete-config' => [ 'MangleFlashPolicy' => 'Since 1.39; no longer has any effect.', 'EnableOpenSearchSuggest' => 'Since 1.35, no longer used', 'AutoloadAttemptLowercase' => 'Since 1.40; no longer has any effect.', ],]
Content objects represent page content, e.g.
Definition Content.php:28
serialize( $format=null)
Serialize this Content object.
The shared interface for all language converters.
Interface for objects (potentially) representing a page that can be viewable and linked to on a wiki.
count()
Get the number of rows in a result object.