[zeromq-dev] matching REQ-REP on one side with PUB & PULL on the other side

Fabien Niñoles fabien.ninoles at gmail.com
Sun Jun 5 20:02:16 CEST 2011

Looks a lot like the collector device I'm working on
(http://www.tzone.org/~fabien/hg/index.cgi/collector/).  Right now, my
only problem with it is that it doesn't allow to call on subgroup but
you still can simply ignore some request on the upper layer of the

Right now, I'm trying to put the piece together with it to make it
work slightly more like a regular device, but this device is already
implement in some of our servers (although only with tens of nodes
groups in two levels of clustering).


2011/5/30  <alotsof at gmx.net>:
> Hi,
> I've read chapter 1 & 2 of the Guide so far, and some posts in the mailing
> list.
> I'm wondering about the following case:
>        A client C asks a server S about the status of the workers W(1..n).
> (the number of workers can vary)
> Here is the implementation I've come up with in terms of communication
> patterns:
>        C:REQ -> REP:S
>                S:PUB  -> SUB:W1..Wn
>                S:PULL <- PUSH:W1..Wn
>        c:REQ <- REP:S
> - C sends a REQ to S
> - S sends the status request through PUB to the workers, who have
> subscribed to a 'broadcast' channel.
> - the workers send their answers through PUSH-PULL to the server
> - the server replies with REP to the client.
> My main problem is: how do I figure out whether I have every answer back?
> Or asked differently, is this the right architecture for the problem I
> want to solve?
> For now, I count the answers coming in through the PULL socket, and when I
> reach the number of known workers, I wrap up my answer to the client.
> It seems to work at first. But later on, I get answers in the server that
> look like replies to earlier requests, so something got out of step.
> Any suggestion?
> --
> NEU: FreePhone - kostenlos mobil telefonieren!
> Jetzt informieren: http://www.gmx.net/de/go/freephone
> _______________________________________________
> 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