Worker

Worker

class Worker (View source)

Methods

void __construct(QueueManager $manager, Dispatcher $events, ExceptionHandler $exceptions)

Create a new queue worker.

void daemon(string $connectionName, string $queue, WorkerOptions $options)

Listen to the given queue in a loop.

void runNextJob(string $connectionName, string $queue, WorkerOptions $options)

Process the next job on the queue.

void process(string $connectionName, Job $job, WorkerOptions $options)

Process a given job from the queue.

bool memoryExceeded(int $memoryLimit)

Determine if the memory limit has been exceeded.

void stop()

Stop listening and bail out of the script.

void sleep(int $seconds)

Sleep the script for a given number of seconds.

void setCache(Repository $cache)

Set the cache repository implementation.

QueueManager getManager()

Get the queue manager instance.

void setManager(QueueManager $manager)

Set the queue manager instance.

doc_Laravel
2016-11-02 16:45:41
Comments
Leave a Comment

Please login to continue.