Skip to content

Queue ​

Type
Class
Namespace
craft\helpers
Inherits
craft\helpers\Queue
Since
3.5.0

Queue helper.

View source

Public Methods ​

MethodDescription
push()Pushes a job to the main app queue.

push() ​

Pushes a job to the main app queue.

View source

Arguments ​

  • $job (yii\queue\JobInterface) – The job to execute via the queue.
  • $priority (integer, null) – The job priority, if supported. Jobs with a lower priority will be executed first. (Default is 1024.)
  • $delay (integer, null) – The execution delay (in seconds), if supported.
  • $ttr (integer, null) – The maximum time the queue should wait around for the job to be handled before assuming it failed.
  • $queue (yii\queue\Queue, null) – The queue to push to

Returns ​

string, null – The new job ID