interface QueueConnector

Connector that produces connected QueueAdapter instances.

Implement this to provide connection acquisition logic for your message broker. Handles pool checkout, connection creation, and termination on error.

Methods

connect(signal?: AbortSignal): Promise<QueueAdapter>

Acquire a connected adapter.

end(): Promise<void>

Close all connections and clean up resources. After calling end(), the connector cannot be used to create new adapters.

Usage

import { type QueueConnector } from ".";