Skip to content

@btravstack/amqp-client


@btravstack/amqp-client ​

Type Aliases ​

AmqpClientSettings ​

ts
type AmqpClientSettings = object;

Defined in: amqp-client/src/index.ts:9

The deployment settings needed to open a publisher connection.

Properties ​

PropertyModifierTypeDefined in
connectTimeoutMs?readonlynumberamqp-client/src/index.ts:11
urlreadonlystringamqp-client/src/index.ts:10

AnyAmqpContract ​

ts
type AnyAmqpContract = Parameters<typeof TypedAmqpClient.create>[0]["contract"];

Defined in: amqp-client/src/index.ts:6

A contract accepted by the underlying typed AMQP client.

Functions ​

amqpClient() ​

ts
function amqpClient<C, Settings, ClientId, SettingsId>(
   port, 
   contract, 
   settings
): Provider<PortInstance<ClientId, TypedAmqpClient<C>>, ConnectionError, PortInstance<SettingsId, Settings> | Scope> & object;

Defined in: amqp-client/src/index.ts:15

Bind a typed AMQP client to an application port for the lifetime of the DI scope.

Type Parameters ​

Type Parameter
C extends ContractDefinition
Settings extends AmqpClientSettings
ClientId extends string
SettingsId extends string

Parameters ​

ParameterType
portPortClassOf<ClientId, TypedAmqpClient<C>>
contractC
settingsPortClassOf<SettingsId, Settings>

Returns ​

Provider<PortInstance<ClientId, TypedAmqpClient<C>>, ConnectionError, PortInstance<SettingsId, Settings> | Scope> & object

Released under the MIT License.