[rabbitmq-discuss] Question about Connections and Channels

Thadeu Russo thadeurc at gmail.com
Sun Dec 19 13:20:05 GMT 2010


Hi,

I need to architect a Java application using rabbitmq as its message broker.
It is a distributed application and the message broker will play the role of
connect the JVMs. Basically, each JVM has sets of objects (currently they
are grouped by host:port) that can change messages to other objects in other
groups in other virtual machines (there is a 1:1 bi-directional relationship
between groups of objects in different JVMs).
The idea of use the broker is to avoid the number of tcp ports I have to
open and also to take advantage of the message delivery guaranties.

The design is simple: each group of objects will have an exchange and 2
queues (incoming and outcoming) to change messages.

I would like to know if you guys advise the following configuration
regarding rabbitmq:

1- Have 1 connection per JVM
2- Have multiple channels to that connection. Each channel will be
associated with those 2 queues

What is concerning me is: the number of sends/receives per channel is high
(about 5k/second). Should I have multiple connections (like a pool), or it
is ok to use just 1 connection? If I have a pool of connections, I
understand they will share the same tcp port, and I could not see any
difference in using a single Connection.

Thanks in advance,

-- 
Thadeu de Russo e Carmo
http://www.thadeu.com.br/
http://www.caelum.com.br/
http://www.caelumobjects.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20101219/e1f438b9/attachment.htm>


More information about the rabbitmq-discuss mailing list