This topic describes how to create a binding whose destination is a specific queue in the Message Queue for RabbitMQ console to allow messages to be routed from an exchange to a queue.

Prerequisites

Before you create a binding, make sure that the following operations are complete:

Procedure

  1. Log on to the Message Queue for RabbitMQ console.
  2. In the Resource Distribution section of the Overview page, select the region where your instance is located.
  3. On the Instances page, click the name of your instance.
  4. In the left-side navigation pane, click Queues.
  5. On the Queues page, click the drop-down arrow next to vhost. From the Change drop-down list, select the vhost of the queue to which you want to bind an exchange. Find the queue, click More in the Actions column, and then select Bound as Destination.
  6. On the Bound as Destination tab of the Queue Details page, click Add Binding.
  7. In the Add Binding panel, set Source Exchange and Binding Key. Then, click Confirm.
    Note
    A binding key must comply with the following rules:
    • A binding key cannot contain Chinese characters.
    • For exchange types other than the topic exchange type, a binding key must be 1 to 255 characters in length, and can contain only letters, digits, hyphens (-), underscores (_), periods (.), and at signs (@).
    • For the topic exchange type, a binding key must be 1 to 255 characters in length, and can contain only letters, digits, hyphens (-), underscores (_), asterisks (*), periods (.), number signs (#), and at signs (@). A binding key can start or end with a number sign (#).

Result

On the Bound as Destination tab, you can view the bound source exchange of the queue. bg_queue_bound_result