RabbitMQ is an open-source message broker for routing and delivering messages between applications. In microservices, it supports asynchronous communication without blocking threads or tightly coupling services. section 9.0 section 9.7
RabbitMQ sends and consumes messages through queues, supports multiple messaging protocols and streams, and uses AMQP 0-9-1 by default. AMQP 1.0 requires a separate plugin and connector. section 9.7
Connect RabbitMQ to a Quarkus application through SmallRye Reactive Messaging:
- Add the connector with quarkus ext add quarkus-messaging-rabbitmq. section 9.7
- Use the same reactive messaging channel model as Kafka, including emitters and incoming consumers. section 9.0 section 9.7
- Map channels to RabbitMQ exchanges and queues through configuration such as mp.messaging.incoming.invoices-rabbitmq.queue.name=invoices. section 9.7
- Consume messages with @Incoming and deserialize received JSON into application objects when required. section 9.7
Asynchronous car-rental billing
A Reservation service emits an invoice when a reservation is created. A Billing service receives it through the invoices-rabbitmq channel, maps the JSON payload to an Invoice, and processes it without making the reservation flow synchronous. section 9.1 section 9.7
Figure 9.1 The car rental architecture changes incorporating reactive messaging channels
Trace how reactive messaging channels connect the Reservation and Billing services in the expanded car-rental architecture. section 9.1




