Note
|
this step is optional. It is appropriate in environments where vCloudDirector events will be pushed through RabbitMQ. |
The VMware vCloudDirector (vCD) can distribute events and notifications to other AMQP server allowing the distribution of messages to other clients, in our case RedHat CloudForms or ManageIQ. Please find below the schema of this setting. Please note that the steps in this manual must be repeated for each vCD organization that you want to support Notifications for.
We assume that vCD is already deployed with corresponding RabbitMQ installation and that you have superuser access to both of them. Furthermore, we assume that vCD already sends messages with notifications to the RabbitMQ – hence exchange named systemExchange already exists inside RabbitMQ.
We also assume that RabbitMQ has Web GUI installed, although all the configuration below can be done via RabbitMQ CLI.
Notification messages that are dropped at RabbitMQ are routed by vCD organization UUID (ORG_UUID). In this section we provide instruction how to get UUID for a specific organization using vCD Web Interface.
-
Log in as superuser of vCloudDirector (not in the organisation, in the provider access)
-
Click on "Manage organizations"
-
Click on a specific organisation
-
Read ORG_UUID from the URL
Navigate to Queues tab and add a new queue there, to the same Virtual host as systemExchange.
Name it queue-<ORG_UUID>
and leave all other parameters on default.
Important
|
Please set parameters exactly as shown in the screenshot above, otherwise ManageIQ will not be able to consume messages (e.g. if you set auto delete to true instead of false). |
Navigate to Exchanges tab and open up vCloud Directors systemExchange details (prefixed with vcd
as set in AMQP broker configuration). In the Bindings subsection add
binding for your queue with following routing key: #.<ORG_UUID>
.
Your queue will now receive all messages regarding specified organization. As a last step we need to add user.
Navigate to Admin tab and add a new user without any tags. Omitting all tags restricts user to connect only to the specific queue. Please note that she will not be able to access the RabbitMQ Web UI as well.
Open up user details and set Configure, Write and Read permission in Permissions subsection. For all three of them simply use queue name and set the permission.
Important
|
Make sure that you click “Set permission” button after you’ve input queue names or else user will not be able to consume any messages. |
Following instructions above the RabbitMQ is configured so that it is safe to provide vCD organization administrator with RabbitMQ endpoint URL and credentials of the created user. She will only be able to connect to the queue that is prepared for her and therefore only consume messages related to her organization.