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

@ -3452,11 +3452,8 @@ function get_formatted_help_string($identifier, $component, $ajax = false) {
global $CFG, $OUTPUT;
$sm = get_string_manager();
if (!$sm->string_exists($identifier, $component) ||
!$sm->string_exists($identifier . '_help', $component)) {
// Strings in the on-disk cache may be dirty - try to rebuild it and check again.
$sm->load_component_strings($component, current_language(), true);
}
// Do not rebuild caches here!
// Devs need to learn to purge all caches after any change or disable $CFG->langstringcache.
$data = new stdClass();