Exemplo n.º 1
0
 /**
  * Initialize the cache
  *
  * @return Zend_Cache_Core
  */
 protected function _initCache()
 {
     // Cache options
     $frontendOptions = array('lifetime' => 1800, 'automatic_serialization' => true);
     $backendOptions = array('lifetime' => 3600, 'cache_dir' => BASE_PATH . '/cache/');
     // Get a Zend_Cache_Core object
     $cache = Zend_Cache::factory('Core', 'File', $frontendOptions, $backendOptions);
     Zend_Registry::set('cache', $cache);
     Digitalus_Cache_Manager::setCacheObject($cache);
     // Return it, so that it can be stored by the bootstrap
     return $cache;
 }