From: Timo Tijhof Date: Thu, 4 Aug 2016 21:47:57 +0000 (-0700) Subject: resourceloader: Disable filesystem cache for Less X-Git-Tag: 1.31.0-rc.0~6164 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_ecrire%28%22suivi_revisions%22%2C%22id_auteur=%24connecte%22%29%20.%20%22?a=commitdiff_plain;h=c2a41baee5cf422489a7b8a8d744e0a0158bbdc3;p=lhc%2Fweb%2Fwiklou.git resourceloader: Disable filesystem cache for Less Follows-up ea862efa7, which enables use of Less_Cache as part of the switch from leafo/lessphp to oyejorge/less.php. Since then 12afb3607 introduced a better caching method in FileModule::compileLessFile(), which: * Uses APC where possible, with fallback to main objectcache. * Verifies both the input file and the indirectly used files have not changed before using the cache. The built-in cache system only seems to check the root file. As such, we're incurring the overhead of generating them and storing on-disk, but raraly ever making use of them. (And even if we do use it when the APC object first expires, it's risky due to the lack of indirect file validation). Bug: T121519 Change-Id: I6e3c66f86a536463488697efc166fb704be0715c --- diff --git a/includes/resourceloader/ResourceLoader.php b/includes/resourceloader/ResourceLoader.php index 1a93f6ef13..85a6954e41 100644 --- a/includes/resourceloader/ResourceLoader.php +++ b/includes/resourceloader/ResourceLoader.php @@ -1578,7 +1578,6 @@ MESSAGE; array_fill_keys( $this->config->get( 'ResourceLoaderLESSImportPaths' ), '' ) ); $parser->SetOption( 'relativeUrls', false ); - $parser->SetCacheDir( $this->config->get( 'CacheDirectory' ) ?: wfTempDir() ); return $parser; }