Skip to main content

RabbitMQ Data Transfer

In RabbitMQ, the consumer doesn't pick up messages from the queue like I assumed.

When the consumer starts, it connects to the broker over a TCP connection. When there is a message for the consumer, the broker pushes it over that same TCP session.

supports both push and pull

RabbitMQ supports both push and pull. Push is the default.

Pull is supported but not recommended. For both, the consumer must start the TCP session. The broker starts no sessions.

active-mq

Multiple Consumers

With many consumers, the broker keeps track. It pushes messages to the consumer TCP connections in a round-robin way.

Producers don't need sessions

Producers need not keep a TCP session open. They can start a session, send messages to the broker, and close it.

An active TCP session need not be maintained using heartbeat or pings.

Topic Exchange

Necessary when a same message must be sent to multiple consumers based on conditions (routing-key).