Moodle APIs 4.2
Moodle 4.2.7 (Build: 20240422)
Classes | Namespaces
allow_temporary_caches.php File Reference

Create and keep an instance of this class to allow temporary caches when caches are disabled. More...

Classes

class  core_cache\allow_temporary_caches
 

Namespaces

namespace  core_cache
  
 

Detailed Description

Create and keep an instance of this class to allow temporary caches when caches are disabled.

This class works together with code in {

See also
cache_factory_disabled}.

The intention is that temporary cache should be short-lived (not for the entire install process), which avoids two problems: first, that we might run out of memory for the caches, and second, that some code e.g. install.php/upgrade.php files, is entitled to assume that caching is not used and make direct database changes.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later