[zeromq-dev] Publish / Subscribe vs Multicast

gonzalo diethelm gdiethelm at dcv.cl
Mon Feb 15 22:39:00 CET 2010


> > I thought I would bind() a socket whenever I want that socket to
receive
> > messages, and I would connect() a socket whenever I want to send
> > messages over it; kind of bind -> passive, connect -> active. Am I
> > totally off the chart here?
> 
> As I understand it, the bind/connect choice has nothing to do with the
> direction of messages, but
> rather which endpoint has a TCP socket that is listening on a port
> (the "server" in traditional language) for incoming connections
> and which makes a TCP connection (the "client").  That is,
> bind/connect refers to the TCP-level actions of bind/connect,
> not message direction.

Sorry, I got mixed up. But what Brian mentions is what I meant by bind
-> passive (listening and waiting), connect -> active (initiating).

Now, within the context of my porting the butterfly example to ZMQ 2.0,
I am doing it exactly this way: apps bind endpoints when they will
listen for connections from somewhere else, and connect endpoints when
they are initiating a connection. But I have not been able to have
several instances of a program bind on the same endpoint and have all of
them (round-robin) receive the messages sent to that endpoint; only the
first app to bind to that endpoint is receiving messages. Am I missing
something?

Thanks and best regards.

-- 
Gonzalo Diethelm



----------------------------------------- 
Declaración de confidencialidad: Este Mensaje esta destinado para
el uso de la o las personas o entidades a quien ha sido dirigido y
puede contener información reservada y confidencial que no puede
ser divulgada, difundida, ni aprovechada en forma alguna. El uso no
autorizado de la información contenida en este correo podrá ser
sancionado de conformidad con la ley chilena. 
Si usted ha recibido este correo electrónico por error, le pedimos
eliminarlo junto con los archivos adjuntos y avisar inmediatamente
al remitente, respondiendo este mensaje. 

"Before printing this e-mail think if is really necesary".
Disclosure: This Message is to be used by the individual,
individuals or entities that it is addressed to and may include
private and confidential information that may not be disclosed,
made public nor used in any way at all. Unauthorized use of the
information in this electronic mail message may be subject to the
penalties set forth by Chilean law. 
If you have received this electronic mail message in error, we ask
you to destroy the message and its attached file(s) and to
immediately notify the sender by answering this message. 




More information about the zeromq-dev mailing list