queue_bind
Binds a queue to an exchange using a specific routing key via the AMQP protocol. This function requires an active broker connection and will attempt to reconnect if the channel is unavailable or if an error occurs during the binding process.
def queue_bind(
amqp_context: object,
queue: string,
exchange: string,
routing_key: string
) - > null
Binds a queue to an exchange with a specific routing key to control how messages are routed.
Parameters
| Name | Type | Description |
|---|---|---|
| amqp_context | object | The context object containing the active AMQP channel and connection state. |
| queue | string | The name of the queue to be bound. |
| exchange | string | The name of the exchange to bind the queue to. |
| routing_key | string | The routing pattern used to filter which messages are sent from the exchange to the queue. |
Returns
| Type | Description |
|---|---|
null | Nothing is returned; the result of the operation is echoed to the console. |