[zeromq-dev] obtain generated identity of socket

Justin Karneges justin at affinix.com
Tue Sep 25 07:57:18 CEST 2012

On Tuesday, September 25, 2012 08:18:03 AM Paul Colomiets wrote:
> Hi Justin,
> On Tue, Sep 25, 2012 at 1:08 AM, Justin Karneges <justin at affinix.com> wrote:
> > Protocol flow goes like this:
> >   1) client pushes a "start" request that gets picked up by one of the
> >   server
> > 
> > instances
> > 
> >   2) server pubs a "clear to send" response that includes a reply address
> > 
> > field, containing the value of the in_stream identity
> > 
> >   3) client sends a series of messages to in_stream, addressed using the
> >   reply> 
> > address
> As your transfers seems big, I think it's ok to open separate (push)
> socket for each transfer. (Or just have a separate socket connected to
> each server).
> I.e. in the "clear to send" message server gives and address where to
> connect to for sending message.
> Creating sockets for each transfer is antipattern if you are doing it
> hundred times per second, but for your use case  it may be cleaner
> than router to router connection.

I do need this to support hundreds-of-times-per-second capacity, and the 
stream sizes may vary wildly (could be one message, could be 200MB of 
messages). Your idea of the client having separate PUSH sockets to each server 
could work as a substitute for the single ROUTER socket. But I do think ROUTER 
is logical, at least on the client side.


More information about the zeromq-dev mailing list