3
3
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
5
5
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />
6
<meta name="generator" content="AsciiDoc 8.6.4" />
6
<meta name="generator" content="AsciiDoc 8.6.6" />
7
7
<title>zmq_socket(3)</title>
8
8
<style type="text/css">
9
/* Shared CSS for AsciiDoc xhtml11 and html5 backends */
13
font-family: Georgia,serif;
10
17
h1, h2, h3, h4, h5, h6,
11
18
div.title, caption.title,
12
19
thead, p.table.header,
14
span#author, span#revnumber, span#revdate, span#revremark,
21
#author, #revnumber, #revdate, #revremark,
16
23
font-family: Arial,Helvetica,sans-serif;
21
font-family: Georgia,"Times New Roman",Times,serif;
30
27
margin: 1em 5% 1em 5%;
102
97
font-weight: bold;
107
span#revnumber, span#revdate, span#revremark {
102
#revnumber, #revdate, #revremark {
111
106
font-size: small;
112
107
border-top: 2px solid silver;
113
108
padding-top: 0.5em;
114
109
margin-top: 4.0em;
118
113
padding-bottom: 0.5em;
122
117
padding-bottom: 0.5em;
126
121
margin-top: 1.5em;
127
122
margin-bottom: 1.5em;
129
div.tableblock, div.imageblock, div.exampleblock, div.verseblock,
124
div.imageblock, div.exampleblock, div.verseblock,
130
125
div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,
131
126
div.admonitionblock {
132
127
margin-top: 1.0em;
267
262
margin-bottom: 0.1em;
270
div.tableblock > table {
271
border: 3px solid #527bbd;
273
thead, p.table.header {
278
266
font-weight: bold;
281
269
white-space: pre;
286
/* Because the table frame attribute is overriden by CSS in most browsers. */
287
div.tableblock > table[frame="void"] {
290
div.tableblock > table[frame="hsides"] {
291
border-left-style: none;
292
border-right-style: none;
294
div.tableblock > table[frame="vsides"] {
295
border-top-style: none;
296
border-bottom-style: none;
301
273
margin-top: 0.8em;
431
403
span.big { font-size: 2em; }
432
404
span.small { font-size: 0.6em; }
433
/* Overrides for manpage documents */
406
span.underline { text-decoration: underline; }
407
span.overline { text-decoration: overline; }
408
span.line-through { text-decoration: line-through; }
417
font-family: monospace;
424
margin-bottom: 1.5em;
426
div.tableblock > table {
427
border: 3px solid #527bbd;
429
thead, p.table.header {
436
/* Because the table frame attribute is overriden by CSS in most browsers. */
437
div.tableblock > table[frame="void"] {
440
div.tableblock > table[frame="hsides"] {
441
border-left-style: none;
442
border-right-style: none;
444
div.tableblock > table[frame="vsides"] {
445
border-top-style: none;
446
border-bottom-style: none;
456
font-family: monospace;
463
margin-bottom: 1.5em;
465
thead, p.tableblock.header {
476
border-color: #527bbd;
477
border-collapse: collapse;
479
th.tableblock, td.tableblock {
483
border-color: #527bbd;
486
table.tableblock.frame-topbot {
487
border-left-style: hidden;
488
border-right-style: hidden;
490
table.tableblock.frame-sides {
491
border-top-style: hidden;
492
border-bottom-style: hidden;
494
table.tableblock.frame-none {
495
border-style: hidden;
498
th.tableblock.halign-left, td.tableblock.halign-left {
501
th.tableblock.halign-center, td.tableblock.halign-center {
504
th.tableblock.halign-right, td.tableblock.halign-right {
508
th.tableblock.valign-top, td.tableblock.valign-top {
511
th.tableblock.valign-middle, td.tableblock.valign-middle {
512
vertical-align: middle;
514
th.tableblock.valign-bottom, td.tableblock.valign-bottom {
515
vertical-align: bottom;
435
525
padding-top: 0.5em;
436
526
padding-bottom: 0.5em;
437
527
border-top: 2px solid silver;
438
528
border-bottom: 2px solid silver;
441
531
border-style: none;
533
body.manpage div.sectionbody {
448
div#toc { display: none; }
538
body.manpage div#toc { display: none; }
452
541
<script type="text/javascript">
454
window.onload = function(){asciidoc.footnotes();}
455
543
var asciidoc = { // Namespace.
457
545
/////////////////////////////////////////////////////////////////////
515
603
var toc = document.getElementById("toc");
608
// Delete existing TOC entries in case we're reloading the TOC.
609
var tocEntriesToRemove = [];
611
for (i = 0; i < toc.childNodes.length; i++) {
612
var entry = toc.childNodes[i];
613
if (entry.nodeName == 'div'
614
&& entry.getAttribute("class")
615
&& entry.getAttribute("class").match(/^toclevel/))
616
tocEntriesToRemove.push(entry);
618
for (i = 0; i < tocEntriesToRemove.length; i++) {
619
toc.removeChild(tocEntriesToRemove[i]);
622
// Rebuild TOC entries.
516
623
var entries = tocEntries(document.getElementById("content"), toclevels);
517
624
for (var i = 0; i < entries.length; ++i) {
518
625
var entry = entries[i];
542
649
footnotes: function () {
650
// Delete existing footnote entries in case we're reloading the footnodes.
652
var noteholder = document.getElementById("footnotes");
656
var entriesToRemove = [];
657
for (i = 0; i < noteholder.childNodes.length; i++) {
658
var entry = noteholder.childNodes[i];
659
if (entry.nodeName == 'div' && entry.getAttribute("class") == "footnote")
660
entriesToRemove.push(entry);
662
for (i = 0; i < entriesToRemove.length; i++) {
663
noteholder.removeChild(entriesToRemove[i]);
666
// Rebuild footnote entries.
543
667
var cont = document.getElementById("content");
544
var noteholder = document.getElementById("footnotes");
545
668
var spans = cont.getElementsByTagName("span");
548
671
for (i=0; i<spans.length; i++) {
549
672
if (spans[i].className == "footnote") {
551
// Use [\s\S] in place of . so multi-line matches work.
552
// Because JavaScript has no s (dotall) regex flag.
553
note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1];
674
var note = spans[i].getAttribute("data-note");
676
// Use [\s\S] in place of . so multi-line matches work.
677
// Because JavaScript has no s (dotall) regex flag.
678
note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1];
680
"[<a id='_footnoteref_" + n + "' href='#_footnote_" + n +
681
"' title='View footnote' class='footnote'>" + n + "</a>]";
682
spans[i].setAttribute("data-note", note);
554
684
noteholder.innerHTML +=
555
685
"<div class='footnote' id='_footnote_" + n + "'>" +
556
686
"<a href='#_footnoteref_" + n + "' title='Return to text'>" +
557
687
n + "</a>. " + note + "</div>";
559
"[<a id='_footnoteref_" + n + "' href='#_footnote_" + n +
560
"' title='View footnote' class='footnote'>" + n + "</a>]";
561
688
var id =spans[i].getAttribute("id");
562
689
if (id != null) refs["#"+id] = n;
709
install: function(toclevels) {
712
function reinstall() {
713
asciidoc.footnotes();
715
asciidoc.toc(toclevels);
719
function reinstallAndRemoveTimer() {
720
clearInterval(timerId);
724
timerId = setInterval(reinstall, 500);
725
if (document.addEventListener)
726
document.addEventListener("DOMContentLoaded", reinstallAndRemoveTimer, false);
728
window.onload = reinstallAndRemoveTimer;
894
1044
from among all connected peers. When sending messages a <em>ZMQ_ROUTER</em> socket shall
895
1045
remove the first part of the message and use it to determine the <em>identity</em> of
896
1046
the peer the message shall be routed to. If the peer does not exist anymore
897
the message shall be silently discarded.</p></div>
1047
the message shall be silently discarded by default, unless <em>ZMQ_ROUTER_BEHAVIOR</em>
1048
socket option is set to <em>1</em>.</p></div>
898
1049
<div class="paragraph"><p>When a <em>ZMQ_ROUTER</em> socket enters an exceptional state due to having reached the
899
high water mark for all peers, or if there are no peers at all, then any
900
messages sent to the socket shall be dropped until the exceptional state ends.
901
Likewise, any messages routed to a non-existent peer or a peer for which the
902
individual high water mark has been reached shall also be dropped.</p></div>
1050
high water mark for all peers, then any messages sent to the socket shall be dropped
1051
until the exceptional state ends. Likewise, any messages routed to a peer for which
1052
the individual high water mark has been reached shall also be dropped.</p></div>
903
1053
<div class="paragraph"><p>When a <em>ZMQ_REQ</em> socket is connected to a <em>ZMQ_ROUTER</em> socket, in addition to the
904
1054
<em>identity</em> of the originating peer each message received shall contain an empty
905
1055
<em>delimiter</em> message part. Hence, the entire structure of each received message