diff options
author | Martin Sustrik <sustrik@250bpm.com> | 2011-01-14 12:38:07 +0100 |
---|---|---|
committer | Martin Sustrik <sustrik@250bpm.com> | 2011-01-14 12:38:07 +0100 |
commit | a348d94c09ab93a19a57ec22a86782e45f1d06ac (patch) | |
tree | a866d0a0cef301b94fc33eb7e0c4bf5a56edfa82 /src/xpub.hpp | |
parent | 58c9830d90fc39727cec88e48f8985a499aa0ee7 (diff) |
Fair queueing of subscriptions added to XPUB socket
Signed-off-by: Martin Sustrik <sustrik@250bpm.com>
Diffstat (limited to 'src/xpub.hpp')
-rw-r--r-- | src/xpub.hpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/xpub.hpp b/src/xpub.hpp index 13baf1f..2b63ec3 100644 --- a/src/xpub.hpp +++ b/src/xpub.hpp @@ -24,6 +24,7 @@ #include "array.hpp" #include "pipe.hpp" #include "dist.hpp" +#include "fq.hpp" namespace zmq { @@ -40,6 +41,8 @@ namespace zmq const blob_t &peer_identity_); int xsend (zmq_msg_t *msg_, int flags_); bool xhas_out (); + int xrecv (zmq_msg_t *msg_, int flags_); + bool xhas_in (); private: @@ -49,6 +52,9 @@ namespace zmq // Distributor of messages holding the list of outbound pipes. dist_t dist; + // Fair queuer for inbound subscriptions. + fq_t fq; + xpub_t (const xpub_t&); const xpub_t &operator = (const xpub_t&); }; |