JobQueueOptions
JobQueueOptions
Options related to the built-in job queue.
Signature
interface JobQueueOptions {
jobQueueStrategy?: JobQueueStrategy;
jobBufferStorageStrategy?: JobBufferStorageStrategy;
activeQueues?: string[];
enableWorkerHealthCheck?: boolean;
prefix?: string;
}
Members
jobQueueStrategy
jobBufferStorageStrategy
JobBufferStorageStrategy
activeQueues
string[]
enableWorkerHealthCheck
boolean
false
When set to true
, a health check will be run on the worker. This is done by
adding a check-worker-health
job to the job queue, which, when successfully
processed by the worker, indicates that it is healthy.
Important Note: This health check is unreliable and can be affected by existing long running jobs, see this issue for further details. For this reason, the health check will be removed entirely in the next major version.
prefix
string
Prefixes all job queue names with the passed string. This is useful with multiple deployments in cloud environments using services such as Amazon SQS or Google Cloud Tasks.
For example, we might have a staging and a production deployment in the same account/project and each one will need its own task queue. We can achieve this with a prefix.