[zeromq-dev] "Broadcast" messages for PUSH-PULL sockets?

Andrew Hume andrew at research.att.com
Mon Mar 14 16:58:54 CET 2011


no cleverness.
just pump no-ops; eventually all of them will see them.
it may take a second or two, but thats okay.
if you have a huge dynamic range (potentially a large number of workers),
then when in no-op mode, the workers might sleep 1s on getting a no-op.
this slow down + load balancing will ensure everyone sees it eventually.

On Mar 14, 2011, at 8:53 AM, Timothy Shead wrote:

> There must be some cleverness here that I'm not seeing - in this case, 
> don't you have the same problem of needing to know the number of workers 
> in advance?  Or are the workers sending some sort of unique worker 
> identifier in their response, so you keep sending no-ops until you stop 
> seeing new workers in the responses?
> 
> Many thanks for the quick response,
> Tim
> 
> On 3/14/11 9:22 AM, Andrew Hume wrote:
>> i use the scheme of having the workers report status back via a
>> PUSH-PULL to the
>> source (or control process). then pump down no-op data until all workers
>> report no-ops.
>> 
>> On Mar 14, 2011, at 8:10 AM, Timothy Shead wrote:
>> 
>>> When streaming a fixed quantity of data through a pipeline via PUSH-PULL
>>> sockets, I find myself wanting to signal all of the downstream workers
>>> when the input data has been exhausted. To do that, I have to send my
>>> "finished" message multiple times, which means that each upstream PUSHer
>>> must be explicitly configured to know how many downstream PULLers there
>>> will be, which spreads-around knowledge of the pipeline topology and
>>> introduces lots of complexity, e.g. waiting for every PULLer to connect,
>>> etc. Is there an easier way to "broadcast" a message to every PULL
>>> socket connected to a PUSH? Using a separate PUB-SUB connection seems
>>> equally problematic - I'm assuming that there's no guarantee that a
>>> published "finished" message would arrive after the last data message in
>>> the PUSH-PULL connection.
>>> 
>>> Thanks in advance,
>>> Tim
>>> 
>>> --
>>> Timothy M. Shead
>>> Sandia National Laboratories
>>> 1461, Scalable Analysis and Visualization
>>> 
>>> _______________________________________________
>>> zeromq-dev mailing list
>>> zeromq-dev at lists.zeromq.org <mailto:zeromq-dev at lists.zeromq.org>
>>> http://lists.zeromq.org/mailman/listinfo/zeromq-dev
>> 
>> 
>> ------------------
>> Andrew Hume (best -> Telework) +1 623-551-2845
>> andrew at research.att.com <mailto:andrew at research.att.com> (Work) +1
>> 973-236-2014
>> AT&T Labs - Research; member of USENIX and LOPSA
>> 
>> 
>> 
>> 
> 
> 
> -- 
> Timothy M. Shead
> Sandia National Laboratories
> 1461, Scalable Analysis and Visualization
> 
> _______________________________________________
> zeromq-dev mailing list
> zeromq-dev at lists.zeromq.org
> http://lists.zeromq.org/mailman/listinfo/zeromq-dev


------------------
Andrew Hume  (best -> Telework) +1 623-551-2845
andrew at research.att.com  (Work) +1 973-236-2014
AT&T Labs - Research; member of USENIX and LOPSA




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20110314/05fb2ff7/attachment.htm>


More information about the zeromq-dev mailing list