Messaging topology The rabbitmq broker is configured as demonstrated below. Key points to note:
commands.fanout exchange is used for routing a command to single queue events.fanout exchange is used for broadcasting the events to all subscribed queues error.fanout exchange collects all unhandled errors, i.e. when the service does not use a dedicated error queue. This is specified on a queue level (x-dead-letter-exchange: error.fanout) or globally via policies audit queue is used to keep track of all the messages sent throught the rabbitmq broker |_commands.fanout |_audit.queue (routing_key=*) |_order.queue (routing_key=createOrder)
|_events.fanout |_audit.queue (routing_key=*) |_order.orderCreated.fanout (routing_key=orderCreated) |_apigateway.queue |_order.orderConfirmed.fanout (routing_key=orderConfirmed) |_apigateway.queue |_notification.queue
|_error.fanout |_error.queue