You are here

public function QueueManager::setQueue in Warmer 2.x

Same name and namespace in other branches
  1. 8 src/QueueManager.php \Drupal\warmer\QueueManager::setQueue()

Sets the queue to use to execute the cache warming operations.

Parameters

\Drupal\Core\Queue\QueueFactory: The queue factory.

bool $is_reliable: Indicates if the queue should be reliable.

File

src/QueueManager.php, line 30

Class

QueueManager
Manage queue items and processing.

Namespace

Drupal\warmer

Code

public function setQueue(QueueFactory $queue_factory, $is_reliable) {
  $queue_factory
    ->get(static::QUEUE_NAME, $is_reliable)
    ->createQueue();
  $this->queue = $queue_factory
    ->get(static::QUEUE_NAME, $is_reliable);
}