abstract class QueueableJob extends Job (View source)

Properties

protected int $jQueueBatchSize
protected JobQueue $jQueueObject

Methods

mixed
start(JobQueue $q)

Start processing a queue Typically this is where you would inject new messages into the queue

mixed
finish(JobQueue $q)

Finish processing a queue

void
processQueueItem(JobQueueMessage $msg)

Process a QueueMessage

__construct()

QueueableJob constructor.

run()

This is disabled since we don't want users to accidentally run a queable job without knowing it

int
getJobQueueBatchSize()

Get the size of the queue batches

getQueueObject()

Get the queue object we're going to use to queue

markStarted()

Mark the queue as started

executeJob()

Executejob for queueable jobs actually starts the queue, runs, and ends all in one function. This happens if we run a job in legacy mode.

Details

abstract mixed start(JobQueue $q)

Start processing a queue Typically this is where you would inject new messages into the queue

Parameters

JobQueue $q

Return Value

mixed

abstract mixed finish(JobQueue $q)

Finish processing a queue

Parameters

JobQueue $q

Return Value

mixed

abstract void processQueueItem(JobQueueMessage $msg)

Process a QueueMessage

Parameters

JobQueueMessage $msg

Return Value

void

__construct()

QueueableJob constructor.

This is here and empty since it'd be a BC break to remove it.

run()

This is disabled since we don't want users to accidentally run a queable job without knowing it

int getJobQueueBatchSize()

Get the size of the queue batches

Return Value

int

JobQueue getQueueObject()

Get the queue object we're going to use to queue

Return Value

JobQueue

markStarted()

Mark the queue as started

executeJob()

Executejob for queueable jobs actually starts the queue, runs, and ends all in one function. This happens if we run a job in legacy mode.