Skip to content

QueueDriverInterface

Minimal contract every queue driver implements.

The in-process SyncQueueDriver implements only this — there is nothing to poll, push() runs the job inline. Persistent drivers additionally implement PollableQueueDriverInterface so queue:work can drive them.

interface QueueDriverInterface

Implemented byPollableQueueDriverInterface, SyncQueueDriver, RecordingQueueDriver, AssertingQueueDriver
SourceQueueDriverInterface.php
MethodDescription
push(JobPayload $payload): voidHands a job off to the driver’s backend.

abstract public function push(JobPayload $payload): void

Hands a job off to the driver’s backend.

Implementors either enqueue the payload for later execution or, for the in-process SyncQueueDriver, run it inline and block until it succeeds or exhausts its retries. A payload carrying a non-null JobPayload::$availableAt must not become visible to a worker before that moment.

ParameterTypeDescription
$payloadJobPayload