class ListenerOptions extends WorkerOptions (View source)

Properties

int $name

The name of the worker.

from  WorkerOptions
int|int[] $backoff

The number of seconds to wait before retrying a job that encountered an uncaught exception.

from  WorkerOptions
int $memory

The maximum amount of RAM the worker may consume.

from  WorkerOptions
int $timeout

The maximum number of seconds a child worker may run.

from  WorkerOptions
int $sleep

The number of seconds to wait in between polling the queue.

from  WorkerOptions
int $rest

The number of seconds to rest between jobs.

from  WorkerOptions
int $maxTries

The maximum number of times a job may be attempted.

from  WorkerOptions
bool $force

Indicates if the worker should run in maintenance mode.

from  WorkerOptions
bool $stopWhenEmpty

Indicates if the worker should stop when the queue is empty.

from  WorkerOptions
int $maxJobs

The maximum number of jobs to run.

from  WorkerOptions
int $maxTime

The maximum number of seconds a worker may live.

from  WorkerOptions
string $environment

The environment the worker should run in.

Methods

void
__construct(string $name = 'default', string|null $environment = null, int|int[] $backoff = 0, int $memory = 128, int $timeout = 60, int $sleep = 3, int $maxTries = 1, bool $force = false, int $rest = 0)

Create a new listener options instance.

Details

void __construct(string $name = 'default', string|null $environment = null, int|int[] $backoff = 0, int $memory = 128, int $timeout = 60, int $sleep = 3, int $maxTries = 1, bool $force = false, int $rest = 0)

Create a new listener options instance.

Parameters

string $name
string|null $environment
int|int[] $backoff
int $memory
int $timeout
int $sleep
int $maxTries
bool $force
int $rest

Return Value

void