library/Garp/Cache/Manager.php
public static function purge($tags = array(), $createClusterJob = true, $cacheDir = false) {
        $messageBag = array();

        if ($tags instanceof Garp_Model_Db) {
            $tags = self::getTagsFromModel($tags);
        }

        $clearOpcache = !empty($tags['opcache']);
        unset($tags['opcache']);

        $messageBag = self::purgeStaticCache($tags, $cacheDir, $messageBag);
        $messageBag = self::purgeMemcachedCache($tags, $messageBag);

        if ($clearOpcache) {
            $messageBag = self::purgeOpcache($messageBag);
        }

        $ini = Zend_Registry::get('config');
        if ($createClusterJob && $ini->app->clusteredHosting) {
            Garp_Cache_Store_Cluster::createJob($tags);
            $messageBag[] = 'Cluster: created clear cache job for cluster';
        }

        return $messageBag;
    }
public static function purge($tags = array(), $createClusterJob = true, $cacheDir = false) {
        $messageBag = array();

        if ($tags instanceof Garp_Model_Db) {
            $tags = self::getTagsFromModel($tags);
        }

        $clearOpcache = !empty($tags['opcache']);
        unset($tags['opcache']);

        $messageBag = self::purgeStaticCache($tags, $cacheDir, $messageBag);
        $messageBag = self::purgeMemcachedCache($tags, $messageBag);

        if ($clearOpcache) {
            $messageBag = self::purgeOpcache($messageBag);
        }

        $ini = Zend_Registry::get('config');
        if ($createClusterJob && $ini->app->clusteredHosting) {
            Garp_Cache_Store_Cluster::createJob($tags);
            $messageBag[] = 'Cluster: created clear cache job for cluster';
        }

        return $messageBag;
    }
public static function purge ( $ tags = array ( ) , $ createClusterJob = true , $ cacheDir = false ) { $ messageBag = array ( ) ; if ( $ tags instanceof Garp_Model_Db ) { $ tags = self :: getTagsFromModel ( $ tags ) ; } $ clearOpcache = ! empty ( $ tags [ 'opcache' ] ) ; unset ( $ tags [ 'opcache' ] ) ; $ messageBag = self :: purgeStaticCache ( $ tags , $ cacheDir , $ messageBag ) ; $ messageBag = self :: purgeMemcachedCache ( $ tags , $ messageBag ) ; if ( $ clearOpcache ) { $ messageBag = self :: purgeOpcache ( $ messageBag ) ; } $ ini = Zend_Registry :: get ( 'config' ) ; if ( $ createClusterJob && $ ini -> app -> clusteredHosting ) { Garp_Cache_Store_Cluster :: createJob ( $ tags ) ; $ messageBag [ ] = 'Cluster: created clear cache job for cluster' ; } return $ messageBag ; }
Purge all cache system wide

@param Array|Garp_Model_Db $tags
@param Boolean $createClusterJob Whether this purge should create a job to clear the other
nodes in this server cluster, if applicable.
@param String $cacheDir Directory which stores static HTML cache files.
@return Void
Purge all cache system wide