[zeromq-dev] Notify send()er that they've hit the high water mark

Edwin Amsler edwinamsler at thinkboxsoftware.com
Mon Jul 9 22:31:43 CEST 2012


Guh? Reeeaally? Through my testing the publisher never errored on send, 
so I didn't test EAGAIN.

A large part of the project is in metaphorical pieces on the floor while 
I redesign something. When I get it back together, I'll test this. Can 
anyone else confirm that that's what happens even on publisher sockets?

On 09/07/2012 3:29 PM, Ian Barber wrote:
>
>
> On Mon, Jul 9, 2012 at 9:24 PM, Edwin Amsler 
> <edwinamsler at thinkboxsoftware.com 
> <mailto:edwinamsler at thinkboxsoftware.com>> wrote:
>
>
>     Ideally, when a HWM condition happened, send() would return false,
>     then I'd test EAGAIN so I could decide for myself whether I should
>     drop the message, or retry later. With that kind of functionality,
>     I could throttle back my producer algorithm so that I exactly meet
>     the demand of ZeroMQ instead of overwhelming/starving it out.
>
>
> This is pretty much how it works with most socket types - if you use 
> the ZMQ_NOBLOCK flag, you'll get the EAGAIN if you've hit HWM.
>
> Ian
>
>
> _______________________________________________
> zeromq-dev mailing list
> zeromq-dev at lists.zeromq.org
> http://lists.zeromq.org/mailman/listinfo/zeromq-dev

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


More information about the zeromq-dev mailing list