JobQueueOptions interface

Everything a job queue needs to connect and behave, given to every constructor in this package.

Only JobQueueOptions.name is required. The rest tune the broker connection, the delivery guarantee and logging, and each carries the default that applies when it is omitted.

Signature:

export interface JobQueueOptions 

Properties

Property

Modifiers

Type

Description

cluster?

[]

(Optional) Broker nodes to connect to, as host/port pairs. The broker is Redis.

logger?

ILogger

(Optional) Logger for the queue's own log and error messages.

name

string

Name of the job queue. Required.

This is the queue's identity, not a label: a JobQueueWorker and a JobQueuePublisher that share a name are two ends of one queue, and two that do not are unrelated queues that will never see each other's jobs.

password?

string

(Optional) Password for authenticating against the broker.

prefix?

string

(Optional) Prefix for every key this queue creates in the broker.

safe?

boolean

(Optional) Whether a job is handed to a worker under a lock, so that a worker dying before it starts does not take the job with it.

safeLockTtl?

number

(Optional) How long, in milliseconds, a job may sit checked out to a worker during safe delivery before it is treated as abandoned.

username?

string

(Optional) Username for authenticating against the broker. Omit it on a broker that takes a password alone, which is the usual Redis setup.

verbose?

boolean

(Optional) Enables the queue's informational tracing.

verboseExtended?

boolean

(Optional) Adds message bodies to the verbose tracing.

Read this page as plain markdown — no HTML, no navigation. For pasting into an LLM, or for an agent to fetch.