TsgcWSPClient_AMQPMethods › BindQueue

BindQueue Method

Binds a queue to an exchange using a routing key (queue.bind).

Syntax

procedure BindQueue(const aChannel, aQueue, aExchange, aRoutingKey: string; aNoWait: Boolean = false; const aArguments: string = '');

Parameters

NameTypeDescription
aChannelconst stringName of the open AMQP channel on which the bind is issued.
aQueueconst stringName of the queue to bind.
aExchangeconst stringName of the exchange the queue will be bound to.
aRoutingKeyconst stringRouting key pattern used to match messages published to the exchange.
aNoWaitBooleanWhen True the client does not wait for the broker to confirm the bind.
aArgumentsconst stringOptional JSON-encoded field-table with additional binding arguments (for example headers-exchange selectors).

Remarks

Fire-and-forget variant. The exchange and the queue must already exist on the broker, otherwise the channel is closed with an error. Use BindQueueEx when you need a synchronous confirmation.

Example

sgcWSPClient_AMQP1.BindQueue('ch1', 'orders', 'ex.orders', 'orders.new');

Back to Methods