DatabaseCacheTagsChecksum::catchException

protected DatabaseCacheTagsChecksum::catchException(\Exception $e)

Act on an exception when cache might be stale.

If the {cachetags} table does not yet exist, that's fine but if the table exists and yet the query failed, then the cache is stale and the exception needs to propagate.

Parameters

\Exception $e: The exception.

Throws

\Exception

File

core/lib/Drupal/Core/Cache/DatabaseCacheTagsChecksum.php, line 202

Class

DatabaseCacheTagsChecksum
Cache tags invalidations checksum implementation that uses the database.

Namespace

Drupal\Core\Cache

Code

protected function catchException(\Exception $e) {
  if ($this->connection->schema()->tableExists('cachetags')) {
    throw $e;
  }
}
doc_Drupal
2016-10-29 08:59:42
Comments
Leave a Comment

Please login to continue.