basalt / queue-sqs/src / SqsQueueDriver
Class: SqsQueueDriver
Defined in: queue-sqs/src/index.ts:104
Amazon SQS driver for @basaltkit/queue. SQS has native per-message delay (up to 15 min) but no priority, which its capabilities reflect honestly — a priority dispatch is caught by the queue's onUnsupported policy.
Retries and backoff are handled at the app level for parity with the other drivers: on failure the message is re-sent with an incremented attempt and a DelaySeconds backoff (clamped to 15 min); an exhausted job is sent to the dead-letter queue (<queue><deadSuffix>). Provide a queueUrl resolver mapping queue names — including the DLQ — to their SQS URLs.
Implements
Constructors
Constructor
> new SqsQueueDriver(options): SqsQueueDriver
Defined in: queue-sqs/src/index.ts:123
Parameters
options
Returns
SqsQueueDriver
Properties
capabilities
> readonly capabilities: DriverCapabilities
Defined in: queue-sqs/src/index.ts:106
What this backend honors — see DriverCapabilities.
Implementation of
name
> readonly name: "sqs" = 'sqs'
Defined in: queue-sqs/src/index.ts:105
Short identifier used in diagnostics (e.g. 'bullmq', 'sync').
Implementation of
Methods
add()
> add(queue, jobName, data, options): Promise<void>
Defined in: queue-sqs/src/index.ts:138
Parameters
queue
string
jobName
string
data
unknown
options
Returns
Promise<void>
Implementation of
close()
> close(): Promise<void>
Defined in: queue-sqs/src/index.ts:168
Returns
Promise<void>
Implementation of
setExecutor()
> setExecutor(executor): void
Defined in: queue-sqs/src/index.ts:134
Called once by the QueueManager — how to execute a received job.
Parameters
executor
Returns
void
Implementation of
startWorker()
> startWorker(queue, options?): void
Defined in: queue-sqs/src/index.ts:158
Starts a worker for the queue (no-op in the sync driver: add executes inline).
Parameters
queue
string
options?
concurrency?
number
Returns
void