Merge "HISTORY: Add MediaWiki 1.2 post-release change notes"
[lhc/web/wiklou.git] / includes / ServiceWiring.php
index e5f891e..73e4543 100644 (file)
@@ -149,7 +149,10 @@ return [
                $lbConf = MWLBFactory::applyDefaultConfig(
                        $mainConfig->get( 'LBFactoryConf' ),
                        $mainConfig,
-                       $services->getConfiguredReadOnlyMode()
+                       $services->getConfiguredReadOnlyMode(),
+                       $services->getLocalServerObjectCache(),
+                       $services->getMainObjectStash(),
+                       $services->getMainWANObjectCache()
                );
                $class = MWLBFactory::getLBFactoryClass( $lbConf );
 
@@ -489,14 +492,10 @@ return [
        },
 
        'SiteLookup' => function ( MediaWikiServices $services ) : SiteLookup {
-               $cacheFile = $services->getMainConfig()->get( 'SitesCacheFile' );
-
-               if ( $cacheFile !== false ) {
-                       return new FileBasedSiteLookup( $cacheFile );
-               } else {
-                       // Use the default SiteStore as the SiteLookup implementation for now
-                       return $services->getSiteStore();
-               }
+               // Use SiteStore as the SiteLookup as well. This was originally separated
+               // to allow for a cacheable read-only interface (using FileBasedSiteLookup),
+               // but this was never used. SiteStore has caching (see below).
+               return $services->getSiteStore();
        },
 
        'SiteStore' => function ( MediaWikiServices $services ) : SiteStore {