[zeromq-dev] Design Question
Andy Ballingall TF
ballingall at thefoundry.co.uk
Fri Jan 18 16:49:51 CET 2013
On 18 January 2013 15:14, Nishant Mittal <nmittal at rblt.com> wrote:
> I have 3 workers (REP) connected to a DLR socket. each worker takes a msg,
> processes and responds... however, as the DLR socket fair-queues.. requests
> are sent like this...
> 1st -> 1st worker
> 2nd -> 2nd worker
> 3rd -> 3rd worker
> 4th -> 1st worker
>
> problem is if the 1st worker is still busy with the 1st request the 4th
> request waits... even if the 2nd and 3rd workers are free. I am "guessing"
> its because of the receive buffer on the REP socket..
>
> is it possible to fix this by setting the ZMQ_RCVHWM to 0?
>
>
I'm not sure if it will help your use case, but have you read through the
load balancing example in the guide?
http://zguide.zeromq.org/page:all#A-Load-Balancing-Message-Broker
Workers are only given work to do if they are free, so you never get the
problem of some workers having a queue of things to process while others
are idle.
Andy
--
Andy Ballingall
Senior Software Engineer
The Foundry
6th Floor, The Communications Building,
48, Leicester Square,
London, WC2H 7LT, UK
Tel: +44 (0)20 7968 6828 - Fax: +44 (0)20 7930 8906
Web: http://www.thefoundry.co.uk/
The Foundry Visionmongers Ltd.
Registered in England and Wales No: 4642027
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20130118/8fd10985/attachment.htm>
More information about the zeromq-dev
mailing list