summaryrefslogtreecommitdiff
path: root/doc/zmq_socket.html
diff options
context:
space:
mode:
Diffstat (limited to 'doc/zmq_socket.html')
-rw-r--r--doc/zmq_socket.html212
1 files changed, 195 insertions, 17 deletions
diff --git a/doc/zmq_socket.html b/doc/zmq_socket.html
index ddab7e1..4546e37 100644
--- a/doc/zmq_socket.html
+++ b/doc/zmq_socket.html
@@ -774,6 +774,173 @@ Drop
</td>
</tr>
</table></div>
+<h4 id="_zmq_xreq">ZMQ_XREQ</h4>
+<div class="paragraph"><p>A socket of type <em>ZMQ_XREQ</em> is an advanced pattern used for extending
+request/reply sockets. Each message sent is load-balanced among all connected
+peers, and each message received is fair-queued from all connected peers.</p></div>
+<div class="paragraph"><p>When a <em>ZMQ_XREQ</em> socket enters an exceptional state due to having reached the
+high water mark for all peers, or if there are no peers at all, then any
+<a href="zmq_send.html">zmq_send(3)</a> operations on the socket shall block until the exceptional
+state ends or at least one peer becomes available for sending; messages are not
+discarded.</p></div>
+<div class="paragraph"><p>When a <em>ZMQ_XREQ</em> socket is connected to a <em>ZMQ_REP</em> socket each message sent
+must consist of an empty message part, the <em>delimiter</em>, followed by one or more
+<em>body parts</em>.</p></div>
+<div class="hdlist"><div class="title">Summary of ZMQ_XREQ characteristics</div><table>
+<tr>
+<td class="hdlist1">
+Compatible peer sockets
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+<em>ZMQ_XREP</em>, <em>ZMQ_REP</em>
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+Direction
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+Bidirectional
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+Send/receive pattern
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+Unrestricted
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+Outgoing routing strategy
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+Load-balanced
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+Incoming routing strategy
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+Fair-queued
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+ZMQ_HWM option action
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+Block
+</p>
+</td>
+</tr>
+</table></div>
+<h4 id="_zmq_xrep">ZMQ_XREP</h4>
+<div class="paragraph"><p>A socket of type <em>ZMQ_XREP</em> is an advanced pattern used for extending
+request/reply sockets. When receiving messages a <em>ZMQ_XREP</em> socket shall
+prepend a message part containing the <em>identity</em> of the originating peer to the
+message before passing it to the application. Messages received are fair-queued
+from among all connected peers. When sending messages a <em>ZMQ_XREP</em> socket shall
+remove the first part of the message and use it to determine the <em>identity</em> of
+the peer the message shall be routed to.</p></div>
+<div class="paragraph"><p>When a <em>ZMQ_XREP</em> socket enters an exceptional state due to having reached the
+high water mark for all peers, or if there are no peers at all, then any
+messages sent to the socket shall be dropped until the exceptional state ends.
+Likewise, any messages routed to a non-existent peer or a peer for which the
+individual high water mark has been reached shall also be dropped.</p></div>
+<div class="paragraph"><p>When a <em>ZMQ_REQ</em> socket is connected to a <em>ZMQ_XREP</em> socket, in addition to the
+<em>identity</em> of the originating peer each message received shall contain an empty
+<em>delimiter</em> message part. Hence, the entire structure of each received message
+as seen by the application becomes: one or more <em>identity</em> parts, <em>delimiter</em>
+part, one or more <em>body parts</em>. When sending replies to a <em>ZMQ_REQ</em> socket the
+application must include the <em>delimiter</em> part.</p></div>
+<div class="hdlist"><div class="title">Summary of ZMQ_XREP characteristics</div><table>
+<tr>
+<td class="hdlist1">
+Compatible peer sockets
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+<em>ZMQ_XREQ</em>, <em>ZMQ_REQ</em>
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+Direction
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+Bidirectional
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+Send/receive pattern
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+Unrestricted
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+Outgoing routing strategy
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+See text
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+Incoming routing strategy
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+Fair-queued
+</p>
+</td>
+</tr>
+<tr>
+<td class="hdlist1">
+ZMQ_HWM option action
+<br />
+</td>
+<td class="hdlist2">
+<p style="margin-top: 0;">
+Drop
+</p>
+</td>
+</tr>
+</table></div>
<h3 id="_publish_subscribe_pattern">Publish-subscribe pattern</h3><div style="clear:left"></div>
<div class="paragraph"><p>The publish-subscribe pattern is used for one-to-many distribution of data from
a single <em>publisher</em> to multiple <em>subscribers</em> in a fanout fashion.</p></div>
@@ -932,17 +1099,18 @@ N/A
a pipeline. Data always flows down the pipeline, and each stage of the pipeline
is connected to at least one <em>node</em>. When a pipeline stage is connected to
multiple <em>nodes</em> data is load-balanced among all connected <em>nodes</em>.</p></div>
-<h4 id="_zmq_downstream">ZMQ_DOWNSTREAM</h4>
-<div class="paragraph"><p>A socket of type <em>ZMQ_DOWNSTREAM</em> is used by a pipeline <em>node</em> to send messages
+<h4 id="_zmq_push">ZMQ_PUSH</h4>
+<div class="paragraph"><p>A socket of type <em>ZMQ_PUSH</em> is used by a pipeline <em>node</em> to send messages
to downstream pipeline <em>nodes</em>. Messages are load-balanced to all connected
downstream <em>nodes</em>. The <em>zmq_recv()</em> function is not implemented for this
socket type.</p></div>
-<div class="paragraph"><p>When a <em>ZMQ_DOWNSTREAM</em> socket enters an exceptional state due to having
-reached the high water mark for all downstream <em>nodes</em>, or if there are no
-downstream <em>nodes</em> at all, then any <a href="zmq_send.html">zmq_send(3)</a> operations on the
-socket shall block until the exceptional state ends or at least one downstream
-<em>node</em> becomes available for sending; messages are not discarded.</p></div>
-<div class="hdlist"><div class="title">Summary of ZMQ_DOWNSTREAM characteristics</div><table>
+<div class="paragraph"><p>When a <em>ZMQ_PUSH</em> socket enters an exceptional state due to having reached the
+high water mark for all downstream <em>nodes</em>, or if there are no downstream
+<em>nodes</em> at all, then any <a href="zmq_send.html">zmq_send(3)</a> operations on the socket shall
+block until the exceptional state ends or at least one downstream <em>node</em>
+becomes available for sending; messages are not discarded.</p></div>
+<div class="paragraph"><p>Deprecated alias: <em>ZMQ_DOWNSTREAM</em>.</p></div>
+<div class="hdlist"><div class="title">Summary of ZMQ_PUSH characteristics</div><table>
<tr>
<td class="hdlist1">
Compatible peer sockets
@@ -950,7 +1118,7 @@ Compatible peer sockets
</td>
<td class="hdlist2">
<p style="margin-top: 0;">
-<em>ZMQ_UPSTREAM</em>
+<em>ZMQ_PULL</em>
</p>
</td>
</tr>
@@ -1010,12 +1178,13 @@ Block
</td>
</tr>
</table></div>
-<h4 id="_zmq_upstream">ZMQ_UPSTREAM</h4>
-<div class="paragraph"><p>A socket of type <em>ZMQ_UPSTREAM</em> is used by a pipeline <em>node</em> to receive
-messages from upstream pipeline <em>nodes</em>. Messages are fair-queued from among
-all connected upstream <em>nodes</em>. The <em>zmq_send()</em> function is not implemented
-for this socket type.</p></div>
-<div class="hdlist"><div class="title">Summary of ZMQ_UPSTREAM characteristics</div><table>
+<h4 id="_zmq_pull">ZMQ_PULL</h4>
+<div class="paragraph"><p>A socket of type <em>ZMQ_PULL</em> is used by a pipeline <em>node</em> to receive messages
+from upstream pipeline <em>nodes</em>. Messages are fair-queued from among all
+connected upstream <em>nodes</em>. The <em>zmq_send()</em> function is not implemented for
+this socket type.</p></div>
+<div class="paragraph"><p>Deprecated alias: <em>ZMQ_UPSTREAM</em>.</p></div>
+<div class="hdlist"><div class="title">Summary of ZMQ_PULL characteristics</div><table>
<tr>
<td class="hdlist1">
Compatible peer sockets
@@ -1023,7 +1192,7 @@ Compatible peer sockets
</td>
<td class="hdlist2">
<p style="margin-top: 0;">
-<em>ZMQ_DOWNSTREAM</em>
+<em>ZMQ_PUSH</em>
</p>
</td>
</tr>
@@ -1197,6 +1366,14 @@ The requested socket <em>type</em> is invalid.
The maximum number of sockets within this <em>context</em> has been exceeded.
</p>
</dd>
+<dt class="hdlist1">
+<strong>EFAULT</strong>
+</dt>
+<dd>
+<p>
+The provided <em>context</em> was not valid (NULL).
+</p>
+</dd>
</dl></div>
</div>
<h2 id="_see_also">SEE ALSO</h2>
@@ -1218,7 +1395,8 @@ Martin Lucina &lt;<a href="mailto:mato@kotelna.sk">mato@kotelna.sk</a>&gt;.</p><
<div id="footnotes"><hr /></div>
<div id="footer">
<div id="footer-text">
-Last updated 2010-06-02 18:30:09 CEST
+ØMQ 2.0.9<br />
+Last updated 2010-09-06 07:11:47 CEST
</div>
</div>
</body>