The queue manager.
The job handler registry.
Drain every currently-ready job across the given queues (one pass).
The queues to drain.
Optionalconnection: string
The connection name.
The number of jobs processed.
Whether the worker is currently running.
True while the loop is active.
Reserve and process one job from a queue.
The queue to consume.
Optionalconnection: string
The connection name.
True when a job was processed, false when the queue was empty.
Run the consume loop until stop is called.
Run options.
ProtectedsleepSleep for the given milliseconds (extracted so it can be controlled in tests).
Milliseconds to sleep.
Stop the consume loop.
StaticcreateCreate a Worker.
The queue manager.
The job handler registry.
A new worker.
The long-running queue consumer.
It reserves the next job, resolves its handler from the JobRegistry, runs it, and acknowledges it; on failure it retries with linear backoff up to
maxAttempts, then dead-letters. On serverless there is no worker: the provider adapter invokes per message and routes to the same registry.