production.
=== Configuration changes in 1.26 ===
+* $wgEnableParserCache was deprecated, set $wgParserCacheType to CACHE_NONE
+ instead if you want to disable the parser cache.
=== New features in 1.26 ===
* Change tags can now be hidden in the interface by disabling the associated
Parser Cache:
stored in: $parserMemc
- controlled by: $wgEnableParserCache
key: $wgDBname:pcache:idhash:$pageid-$renderkey!$hash
$pageid: id of the page
$renderkey: 1 if action=render, 0 otherwise
$wgFileCacheDepth = 2;
/**
- * Keep parsed pages in a cache (objectcache table or memcached)
- * to speed up output of the same page viewed by another user with the
- * same options.
- *
- * This can provide a significant speedup for medium to large pages,
- * so you probably want to keep it on. Extensions that conflict with the
- * parser cache should disable the cache on a per-page basis instead.
+ * Kept for extension compatibility; see $wgParserCacheType
+ * @deprecated 1.26
*/
$wgEnableParserCache = true;
$wgGitInfoCacheDirectory = "{$wgCacheDirectory}/gitinfo";
}
+if ( $wgEnableParserCache === false ) {
+ $wgParserCacheType = CACHE_NONE;
+}
+
// Fix path to icon images after they were moved in 1.24
if ( $wgRightsIcon ) {
$wgRightsIcon = str_replace(
* @return bool
*/
public function isParserCacheUsed( ParserOptions $parserOptions, $oldid ) {
- global $wgEnableParserCache;
-
- return $wgEnableParserCache
- && $parserOptions->getStubThreshold() == 0
+ return $parserOptions->getStubThreshold() == 0
&& $this->exists()
&& ( $oldid === null || $oldid === 0 || $oldid === $this->getLatest() )
&& $this->getContentHandler()->isParserCacheSupported();
* - 'no-change': don't update the article count, ever
*/
public function doEditUpdates( Revision $revision, User $user, array $options = array() ) {
- global $wgEnableParserCache;
-
$options += array(
'changed' => true,
'created' => false,
}
// Save it to the parser cache
- if ( $wgEnableParserCache ) {
- $parserCache = ParserCache::singleton();
- $parserCache->save(
- $editInfo->output, $this, $editInfo->popts, $editInfo->timestamp, $editInfo->revid
- );
- }
+ ParserCache::singleton()->save(
+ $editInfo->output, $this, $editInfo->popts, $editInfo->timestamp, $editInfo->revid
+ );
// Update the links tables and other secondary data
if ( $content ) {
static function setUp() {
global $wgParser, $wgParserConf, $IP, $messageMemc, $wgMemc,
- $wgUser, $wgLang, $wgOut, $wgRequest, $wgStyleDirectory, $wgEnableParserCache,
+ $wgUser, $wgLang, $wgOut, $wgRequest, $wgStyleDirectory,
$wgExtraNamespaces, $wgNamespaceAliases, $wgNamespaceProtection, $wgLocalFileRepo,
$wgExtraInterlanguageLinkPrefixes, $wgLocalInterwikis,
$parserMemc, $wgThumbnailScriptPath, $wgScriptPath,
$wgParserCacheType = CACHE_NONE;
}
- $wgEnableParserCache = false;
DeferredUpdates::clearPendingUpdates();
$wgMemc = wfGetMainCache(); // checks $wgMainCacheType
$messageMemc = wfGetMessageCacheStorage();
);
$tmpGlobals['wgForeignFileRepos'] = array();
$tmpGlobals['wgDefaultExternalStore'] = array();
- $tmpGlobals['wgEnableParserCache'] = false;
+ $tmpGlobals['wgParserCacheType'] = CACHE_NONE;
$tmpGlobals['wgCapitalLinks'] = true;
$tmpGlobals['wgNoFollowLinks'] = true;
$tmpGlobals['wgNoFollowDomainExceptions'] = array();
protected function setUp() {
global $wgParser, $wgParserConf, $IP, $messageMemc, $wgMemc, $wgUser,
$wgLang, $wgOut, $wgRequest, $wgStyleDirectory,
- $wgEnableParserCache, $wgNamespaceAliases, $wgNamespaceProtection,
+ $wgParserCacheType, $wgNamespaceAliases, $wgNamespaceProtection,
$parserMemc;
$tmpGlobals = array();
$wgNamespaceAliases['Image'] = NS_FILE;
$wgNamespaceAliases['Image_talk'] = NS_FILE_TALK;
- $wgEnableParserCache = false;
+ $wgParserCacheType = CACHE_NONE;
DeferredUpdates::clearPendingUpdates();
$wgMemc = wfGetMainCache();
$messageMemc = wfGetMessageCacheStorage();