public function Store::cleanup

Cleanups storage.

Overrides StoreInterface::cleanup

File

drupal/core/vendor/symfony/http-kernel/Symfony/Component/HttpKernel/HttpCache/Store.php, line 49

Class

Store
Store implements all the logic for storing cache metadata (Request and Response headers).

Namespace

Symfony\Component\HttpKernel\HttpCache

Code

public function cleanup() {

  // unlock everything
  foreach ($this->locks as $lock) {
    @unlink($lock);
  }
  $error = error_get_last();
  if (1 === $error['type'] && false === headers_sent()) {

    // send a 503
    header('HTTP/1.0 503 Service Unavailable');
    header('Retry-After: 10');
    echo '503 Service Unavailable';
  }
}