[zeromq-dev] zmq REQ to multiple REP sockets
Ian Barber
ian.barber at gmail.com
Wed Feb 9 06:46:29 CET 2011
On Wed, Feb 9, 2011 at 3:53 AM, James Bardin <jbardin at bu.edu> wrote:
>
> A timeout of some sort would be great (by the sound of it, it's
> planned?), at least in the higher level libraries where a lot pieces
> are hidden. As a newcomer using python, what I ran into immediately
> was a blocking call to recv, with no obvious way to program around it
> when it blocks indefinitely, and as a defensive programmer, I always
> count on that happening.
>
> -jim
>
> You can pass a zmq.NOBLOCK to recv to have it return instantly if that's
what you're looking for - assuming that sufficient time has passed for a
message to be delivered to the socket you could equate a failure as a
failure of the node - using poll just lets you give it a specific timeout so
it will wait for so long before doing the same thing.
Ian
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20110209/8ae9aeed/attachment-0001.htm>
More information about the zeromq-dev
mailing list