ItemWarmer.php in Warmer 8
Same filename and directory in other branches
Namespace
Drupal\warmer\Plugin\QueueWorkerFile
src/Plugin/QueueWorker/ItemWarmer.phpView source
<?php
namespace Drupal\warmer\Plugin\QueueWorker;
use Drupal\Core\Queue\QueueWorkerBase;
use Drupal\warmer\QueueData;
/**
* Process the items queued for warming.
*
* @QueueWorker(
* id = "warmer",
* title = @Translation("Cache warmer"),
* cron = {"time" = 60}
* )
*/
class ItemWarmer extends QueueWorkerBase {
/**
* {@inheritdoc}
*/
public function processItem($data) {
if (!$data instanceof QueueData) {
return;
}
$data
->process();
}
}
Classes
Name | Description |
---|---|
ItemWarmer | Process the items queued for warming. |