[zeromq-dev] Dropping connection end points dynamically

Radha Krishna Srimanthula srimanthula.radhakrishna at gmail.com
Wed Apr 18 21:23:56 CEST 2012


Hi,

My scenario is this:

I have a set of networked devices, which need to be a part of an
installation group. Its a requirement to cater to scenarios where existing
devices can go off the installation and new devices get into the
installation. Each device does auto-discovery to figure who are in the
group at any given point in time and communicates to all of 'em using
pub-sub, for which I am using zeromq.

The above scenario places an expectation that the subscription list that
each device maintains change (with addition/ removal of devices from the
group). In this context, I have a few questions:

   1. I plan to create the socket, manage the end points and do the pub-sub
   communication in three different threads. For various legacy reasons, I
   need to use the existing threading model -based on pthreads- for now (I
   plan to move to zeromq's threading model later). Is there a potential
   failure scenario here? Is it ok to use three different threads for the
   above said purposes?
   2. We have mechanisms to create multiple connection end points, one for
   each publisher and subscribe to their updates. In a dynamic scenario like
   the one mentioned above, is there an API to drop an end point and stop
   subscribing to updates from the publisher?

Any help will be greatly appreciated.

--
Regards,
Radha
<http://www.sradhakrishna.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20120418/060cfa9a/attachment.htm>


More information about the zeromq-dev mailing list