function DatabaseBackend::doDeleteMultiple

Deletes items from the cache bin table.

Parameters

string[] $cids: An array of normalized cache IDs.

1 call to DatabaseBackend::doDeleteMultiple()
DatabaseBackend::deleteMultiple in core/lib/Drupal/Core/Cache/DatabaseBackend.php
Deletes multiple items from the cache.

File

core/lib/Drupal/Core/Cache/DatabaseBackend.php, line 340

Class

DatabaseBackend
Defines a default cache implementation.

Namespace

Drupal\Core\Cache

Code

protected function doDeleteMultiple(array $cids) : void {
  // Delete the items in groups of 1000. This keeps each query small.
  foreach (array_chunk($cids, 1000) as $cids_chunk) {
    $this->connection
      ->delete($this->bin)
      ->condition('cid', $cids_chunk, 'IN')
      ->execute();
  }
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.