function QueueWorkerManager::processDefinition

Same name and namespace in other branches
  1. 9 core/lib/Drupal/Core/Queue/QueueWorkerManager.php \Drupal\Core\Queue\QueueWorkerManager::processDefinition()
  2. 10 core/lib/Drupal/Core/Queue/QueueWorkerManager.php \Drupal\Core\Queue\QueueWorkerManager::processDefinition()
  3. 11.x core/lib/Drupal/Core/Queue/QueueWorkerManager.php \Drupal\Core\Queue\QueueWorkerManager::processDefinition()

Overrides DefaultPluginManager::processDefinition

File

core/lib/Drupal/Core/Queue/QueueWorkerManager.php, line 40

Class

QueueWorkerManager
Defines the queue worker manager.

Namespace

Drupal\Core\Queue

Code

public function processDefinition(&$definition, $plugin_id) {
    parent::processDefinition($definition, $plugin_id);
    // Assign a default time if a cron is specified.
    if (isset($definition['cron'])) {
        $definition['cron'] += [
            'time' => 15,
        ];
    }
}

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