[zeromq-dev] Publish / Subscribe vs Multicast

Martin Sustrik sustrik at 250bpm.com
Mon Feb 15 19:12:15 CET 2010


Gonzalo,

>> I would definitely use ZMQ_UPSTREAM and ZMQ_DOWNSTREM sockets. Hava a
>> look at the following article:
>>
>> http://www.zeromq.org/tutorials:butterfly
>>
>> (The code samples use old API so just ignore them.)
>>
>> Is that what you are aiming for?
> 
> Sweet! Yes, that is the scenario I am researching. However, I could not
> find that tutorial anywhere in the downloaded source code (for Windows).
> Do I need to get it from the repo? Or perhaps it is not included anymore
> (since you mention an old API)?

It is not included anymore. Unfortunately, we have not enough resources 
to port everything from version 1.0 to version 2.0 straight away.

Anyway, the principle holds. Use ZMQ_UPSTREAM socket to get messages 
from the previous object, use ZMQ_DOWNSTREAM to send them further on.

The component named 'intermediate' in the tutotial, the one that 
collects results from previous processing step and load-balancing them 
to processes handling next processing step, now exists as a precompiled 
binary (zmq_streamer) so you don't have to write it by hand.

Martin




More information about the zeromq-dev mailing list