You are here

function workspace_queue_info_alter in Workspace 8

Implements hook_queue_info_alter().

File

./workspace.module, line 214

Code

function workspace_queue_info_alter(&$queues) {
  $replication_blocked = \Drupal::state()
    ->get('workspace.last_replication_failed', FALSE);
  if (isset($queues['workspace_replication']) && $replication_blocked) {

    // Let's spend 60 seconds instead of 600 seconds when the replication is
    // blocked.
    $queues['workspace_replication']['cron']['time'] = 60;
  }
}