public function Database::releaseJob in Advanced Queue 8
Releases the job with the given ID.
Parameters
string $job_id: The job ID.
Overrides SupportsReleasingJobsInterface::releaseJob
File
- src/
Plugin/ AdvancedQueue/ Backend/ Database.php, line 231
Class
- Database
- Provides the database queue backend.
Namespace
Drupal\advancedqueue\Plugin\AdvancedQueue\BackendCode
public function releaseJob($job_id) {
$this->connection
->update('advancedqueue')
->fields([
'state' => Job::STATE_QUEUED,
'expires' => 0,
])
->condition('job_id', $job_id)
->execute();
}