diff options
author | Martin Sustrik <sustrik@250bpm.com> | 2011-06-19 16:39:27 +0200 |
---|---|---|
committer | Martin Sustrik <sustrik@250bpm.com> | 2011-06-19 16:39:27 +0200 |
commit | ed680a395edb9260eced8289b33041248782f979 (patch) | |
tree | 9209ca7a657631b5eeb5293ad245bce3a718cd41 | |
parent | 9f4d3767fed58ddfa52f63692c6169bfdbcec2e3 (diff) |
Documentation for XPUB and XSUB socket added
Signed-off-by: Martin Sustrik <sustrik@250bpm.com>
-rw-r--r-- | doc/zmq_socket.txt | 41 |
1 files changed, 33 insertions, 8 deletions
diff --git a/doc/zmq_socket.txt b/doc/zmq_socket.txt index b681147..badb9ef 100644 --- a/doc/zmq_socket.txt +++ b/doc/zmq_socket.txt @@ -80,7 +80,6 @@ messages are not discarded. [horizontal] .Summary of ZMQ_REQ characteristics Compatible peer sockets:: 'ZMQ_REP' -Direction:: Bidirectional Send/receive pattern:: Send, Receive, Send, Receive, ... Outgoing routing strategy:: Load-balanced Incoming routing strategy:: Last peer @@ -103,7 +102,6 @@ question shall be dropped until the exceptional state ends. [horizontal] .Summary of ZMQ_REP characteristics Compatible peer sockets:: 'ZMQ_REQ' -Direction:: Bidirectional Send/receive pattern:: Receive, Send, Receive, Send, ... Incoming routing strategy:: Fair-queued Outgoing routing strategy:: Last peer @@ -129,7 +127,6 @@ _body parts_. [horizontal] .Summary of ZMQ_XREQ characteristics Compatible peer sockets:: 'ZMQ_XREP', 'ZMQ_REP' -Direction:: Bidirectional Send/receive pattern:: Unrestricted Outgoing routing strategy:: Load-balanced Incoming routing strategy:: Fair-queued @@ -163,7 +160,6 @@ application must include the _delimiter_ part. [horizontal] .Summary of ZMQ_XREP characteristics Compatible peer sockets:: 'ZMQ_XREQ', 'ZMQ_REQ' -Direction:: Bidirectional Send/receive pattern:: Unrestricted Outgoing routing strategy:: See text Incoming routing strategy:: Fair-queued @@ -189,8 +185,7 @@ ends. The _zmq_send()_ function shall never block for this socket type. [horizontal] .Summary of ZMQ_PUB characteristics -Compatible peer sockets:: 'ZMQ_SUB' -Direction:: Unidirectional +Compatible peer sockets:: 'ZMQ_SUB', 'ZMQ_XSUB' Send/receive pattern:: Send only Incoming routing strategy:: N/A Outgoing routing strategy:: Fan out @@ -207,14 +202,44 @@ implemented for this socket type. [horizontal] .Summary of ZMQ_SUB characteristics -Compatible peer sockets:: 'ZMQ_PUB' -Direction:: Unidirectional +Compatible peer sockets:: 'ZMQ_PUB', 'ZMQ_XPUB' Send/receive pattern:: Receive only Incoming routing strategy:: Fair-queued Outgoing routing strategy:: N/A ZMQ_HWM option action:: Drop +ZMQ_XPUB +^^^^^^^^ +Same as ZMQ_PUB except that you can receive subscriptions from the peers +in form of incoming messages. Subscription message is a byte 1 (for +subscriptions) or byte 0 (for unsubscriptions) followed by the subscription +body. + +[horizontal] +.Summary of ZMQ_XPUB characteristics +Compatible peer sockets:: 'ZMQ_SUB', 'ZMQ_XSUB' +Send/receive pattern:: Send messages, receive subscriptions +Incoming routing strategy:: N/A +Outgoing routing strategy:: Fan out +ZMQ_HWM option action:: Drop + + +ZMQ_SUB +^^^^^^^ +Same as ZMQ_SUB except that you subscribe by sending subscription messages to +the socket. Subscription message is a byte 1 (for subscriptions) or byte 0 +(for unsubscriptions) followed by the subscription body. + +[horizontal] +.Summary of ZMQ_XSUB characteristics +Compatible peer sockets:: 'ZMQ_PUB', 'ZMQ_XPUB' +Send/receive pattern:: Receive messages, send subscriptions +Incoming routing strategy:: Fair-queued +Outgoing routing strategy:: N/A +ZMQ_HWM option action:: Drop + + Pipeline pattern ~~~~~~~~~~~~~~~~ The pipeline pattern is used for distributing data to _nodes_ arranged in |