RabbitMQ is one of middlewares. Middlewares are mostly used to decoupling, which makes producers don’t need to know who is the consumers.
When producers generate huge amount of data, consumers cannot consume with a proper rate. We need a middleware to store these data for future use, which achieves bidirectional decoupling.
Features of RabbitMQ
Exchange
- Retrieve and transmit messages to target queue
direct: transmit messages to target queue of routingKey
topic: transmit messages by rules
headers:
fanout: transmit messages to all binded queue