You are here

class AcquiaPurgeExecutorPageCache in Acquia Purge 7

Executor that pre-clears URLs from Drupal's page cache.

Hierarchy

Expanded class hierarchy of AcquiaPurgeExecutorPageCache

1 string reference to 'AcquiaPurgeExecutorPageCache'
AcquiaPurgeCapacity::httpRequestsFactor in lib/AcquiaPurgeCapacity.php
Get the number of expected HTTP requests per single queue item.

File

lib/executor/AcquiaPurgeExecutorPageCache.php, line 11
Contains AcquiaPurgeExecutorPageCache.

View source
class AcquiaPurgeExecutorPageCache extends AcquiaPurgeExecutorBase implements AcquiaPurgeExecutorInterface {

  /**
   * {@inheritdoc}
   */
  public static function isEnabled(AcquiaPurgeService $service) {
    if ($service
      ->hostingInfo()
      ->isPageCacheFake()) {
      return FALSE;
    }
    return TRUE;
  }

  /**
   * {@inheritdoc}
   */
  public function invalidate($invalidations) {
    foreach ($invalidations as $invalidation) {
      cache_clear_all($invalidation
        ->getUri(), 'cache_page');
      $invalidation
        ->setStatusSucceeded();
    }
  }

}

Members

Namesort descending Modifiers Type Description Overrides
AcquiaPurgeExecutorBase::$class_request protected property The invalidation class to instantiate invalidation objects from.
AcquiaPurgeExecutorBase::$id protected property The unique identifier for this executor.
AcquiaPurgeExecutorBase::$log_successes protected property Whether to log successes or not.
AcquiaPurgeExecutorBase::$service protected property The Acquia Purge service object.
AcquiaPurgeExecutorBase::exportDebugSymbols protected function Turn a PHP variable into a string with data type information for debugging.
AcquiaPurgeExecutorBase::getId public function Get a unique identifier for this executor. Overrides AcquiaPurgeExecutorInterface::getId
AcquiaPurgeExecutorBase::getRequest public function Instantiate a new request object. Overrides AcquiaPurgeExecutorInterface::getRequest
AcquiaPurgeExecutorBase::requestsExecute public function Execute a series of HTTP requests efficiently through cURL's multi handler. Overrides AcquiaPurgeExecutorInterface::requestsExecute
AcquiaPurgeExecutorBase::requestsLog public function Log a series of requests according to their 'result' properties. Overrides AcquiaPurgeExecutorInterface::requestsLog
AcquiaPurgeExecutorBase::__construct public function Construct a new AcquiaPurgeExecutorBase instance. Overrides AcquiaPurgeExecutorInterface::__construct
AcquiaPurgeExecutorPageCache::invalidate public function Invalidate one or multiple paths from an external layer. Overrides AcquiaPurgeExecutorInterface::invalidate
AcquiaPurgeExecutorPageCache::isEnabled public static function Determine if the executor is enabled or not. Overrides AcquiaPurgeExecutorInterface::isEnabled