MDL-41019 improve language caching

Includes:
* no more hacky reloads, everything is written only once and kept until cache reset
* lang menu list is now cached in MUC
* both string and lang menu caches are compatible with local caches on cluster nodes
* config-dist.php cleanup
This commit is contained in:
Petr Škoda 2013-08-04 00:01:58 +02:00
parent 99a9d8d937
commit 598a82c950
9 changed files with 134 additions and 179 deletions

View file

@ -6635,14 +6635,7 @@ function get_string_manager($forcereload=false) {
$translist = explode(',', $CFG->langlist);
}
if (empty($CFG->langmenucachefile)) {
$langmenucache = $CFG->cachedir . '/languages';
} else {
$langmenucache = $CFG->langmenucachefile;
}
$singleton = new core_string_manager_standard($CFG->langotherroot, $CFG->langlocalroot,
!empty($CFG->langstringcache), $translist, $langmenucache);
$singleton = new core_string_manager_standard($CFG->langotherroot, $CFG->langlocalroot, $translist);
} else {
$singleton = new core_string_manager_install();