An abstract interface for a message queue.
readonly
optional
nativeRetrial: boolean
Whether the message queue backend provides native retry mechanisms.
When true
, Fedify will skip its own retry logic and rely on the backend
to handle retries. When false
or omitted, Fedify will handle retries
using its own retry policies.
optional
enqueueMany: (messages: any[],options?: MessageQueueEnqueueOptions,) => Promise<void>
Enqueues multiple messages in the queue. This operation is optional, and may not be supported by all implementations. If not supported, Fedify will invoke enqueue for each message.
enqueue(message: any,options?: MessageQueueEnqueueOptions,): Promise<void>
Enqueues a message in the queue.
listen(handler: (message: any) => Promise<void> | void,options?: MessageQueueListenOptions,): Promise<void>
Listens for messages in the queue.