8. vCloud Management and Monitoring Examples : 8.2 AMQP Messages : 8.2.2 Example : 8.2.2.3. Exchange Routing
   
8.2.2.3. Exchange Routing
The AMQP broker uses routing as a way to filter vCloud Director notification messages and send them to the appropriate queue for multiple consumers. For example, a public cloud provider can filter messages based on organization and send each customers notifications to a separate queue for isolation of logging information. The vCloud Director routing key syntax is as follows:
<operationSuccess>.<entityUUID>.<orgUUID>.<userUUID>.<subType1>.<subType2>….<subtypeN>.taskName
For example, to route only VM create messages to a queue, the routing key would be:
true.#.com.vmware.vcloud.event.vm.create
vCloud Director sets sane routing keys in the messages that are generated. This example uses the # (hash) routing key because this is a wildcard match on one or more segments of a routing key. This effectively routes all messages generated by vCloud Director of type vm.create to a notificationQueue. If you are interested in specific messages being routed to the appropriate queue, a non-wildcard or selective wildcard (*) routing key can be used.
Blocking tasks messages have similar identifier with the object being the blocking task. The blocking task references the following:
*Its parent task – The suspended task referencing the object and the task parameters attributes it was set with in the original request.
*TaskOwner – The object on which the task operates.
*The actions that can be taken on this blocking task (resume, abort, fail, updateProgress).
Receiving and acting upon on the blockings task is accomplished with the vCloud director API callbacks. System admin privileges are required to perform these operations.