[zeromq-dev] Windows and PGM

Martin Sustrik sustrik at 250bpm.com
Sat Mar 27 07:47:17 CET 2010

Brian, Jon, Gonzalo,

>> So what you'll have would look something like this:
>> void *ear = zmq_socket (ctx, ZMQ_SUB);
>> zmq_bind (ear, "tcp://");
>> zmq_setsockopt (ear, ZMQ_SUBSCRIBE, "forex.", 6);
>> void *mouth = zmq_socket (ctx, ZMQ_PUB);
>> zmq_connect (ear, "tcp://");
>> zmq_device (ZMQ_FORWARDER, ear, mouth);
> I like this API alot.  Also, this idea would solve the issue of
> implementing a heartbeat mechanism.  It would just be a device and you
> could pass it any socket you want as the responder.  I do like the
> idea of having the event loop of the device hidden inside zmq_device
> and run in a thread.  Because of the GIL/threading issues in Python,
> we definitely need to have devices run in C++ thread.

OK. AFAIU there's a concensus on the ultimate goal here. Now the 
question is how to get there via sequence of small steps.

Maybe starting with zmq_device call that would do the loop and never 
exist would be the easiest. It's ugly and won't work for python, but at 
least it would further the issue a bit.


More information about the zeromq-dev mailing list