[zeromq-dev] Asynchronous Client-Server Pattern in ZGuide

Pieter Hintjens ph at imatix.com
Thu Nov 15 07:37:12 CET 2012


If you use a DEALER/ROUTER connect then the dealer has to connect to
the router before the router can reply to it. That's the
load-balancing pattern already explained.

-Pieter

On Thu, Nov 15, 2012 at 3:35 PM, Ilja Golshtein <ilejncs at narod.ru> wrote:
> Pieter,
>
> my question is if the description of
> what should be changed to switch
> from DEALER/DEALER to DEALER/ROUTER
> correct.
>
>
> 15.11.2012, 03:20, "Pieter Hintjens" <ph at imatix.com>:
>> Ilja,
>>
>> Correction, the text is right, though perhaps confusing. It explains
>> two options (router-dealer, dealer-dealer), and then explains why we
>> chose dealer-dealer in this case.
>>
>> -Pieter
>>
>> On Thu, Nov 15, 2012 at 8:17 AM, Pieter Hintjens <ph at imatix.com> wrote:
>>
>>>  You're right, the text is wrong. The server and workers talk using
>>>  DEALER-to-DEALER. I'll fix the text, thanks for catching this.
>>>
>>>  -Pieter
>>>
>>>  On Thu, Nov 15, 2012 at 1:10 AM, Ilja Golshtein <ilejncs at narod.ru> wrote:
>>>>  Hello,
>>>>  Pieter,
>>>>  All.
>>>>
>>>>  In ZGuide in "The Asynchronous Client-Server Pattern" section we have
>>>>  ==
>>>>  Workers get unaddressed messages, and we manage the connections from server thread to worker threads explicitly using a ROUTER socket as backend. This would require that workers start by telling the server they exist, which can then route requests to workers and track which client is 'connected' to which worker. This is the load-balancing pattern again.
>>>>  ==
>>>>
>>>>  Since we are talking about Routers at workers' side, I am not sure why "This would require that workers start by telling the server they exist".
>>>>  It is server who should start a communication and he does it anyway.
>>>>
>>>>  Actually switching from DEALER to ROUTER at worker's side requires reading and writing extra frame, which is identity.
>>>>
>>>>  Do I miss something?
>>>>
>>>>  Thanks.
>>>>
>>>>  --
>>>>  Best regards
>>>>  Ilja Golshtein
>>>>  _______________________________________________
>>>>  zeromq-dev mailing list
>>>>  zeromq-dev at lists.zeromq.org
>>>>  http://lists.zeromq.org/mailman/listinfo/zeromq-dev
>>
>> _______________________________________________
>> zeromq-dev mailing list
>> zeromq-dev at lists.zeromq.org
>> http://lists.zeromq.org/mailman/listinfo/zeromq-dev
>
> --
> Best regards
> Ilja Golshtein
> _______________________________________________
> zeromq-dev mailing list
> zeromq-dev at lists.zeromq.org
> http://lists.zeromq.org/mailman/listinfo/zeromq-dev



More information about the zeromq-dev mailing list