Skip to content

Commit

Permalink
Initial documentation for the new ZMQ_PROTOCOL socket option
Browse files Browse the repository at this point in the history
  • Loading branch information
methodmissing committed Aug 4, 2012
1 parent 42eba44 commit 0578ec8
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
14 changes: 14 additions & 0 deletions doc/zmq_getsockopt.txt
Original file line number Diff line number Diff line change
Expand Up @@ -455,6 +455,20 @@ Option value unit:: -1,>0
Default value:: -1 (leave to OS default)
Applicable socket types:: all, when using TCP transports.

ZMQ_PROTOCOL: Wire protocol version in use
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Retrieve the wire protocol version used by this socket (pipe actually). A value
of `1` designates backwards compatibility with existing 2.x pub-sub components
in an existing topology. A value of `0` means subscription forwarding is
enabled for pub-sub pairs.

[horizontal]
Option value type:: int
Option value unit:: >0
Default value:: 0 (with subscription forwarding)
Applicable socket types:: all (only respected by ZMQ_PUB and ZMQ_SUB)

RETURN VALUE
------------
The _zmq_getsockopt()_ function shall return zero if successful. Otherwise it
Expand Down
14 changes: 14 additions & 0 deletions doc/zmq_setsockopt.txt
Original file line number Diff line number Diff line change
Expand Up @@ -431,6 +431,20 @@ Default value:: no filters (allow from all)
Applicable socket types:: all listening sockets, when using TCP transports.


ZMQ_PROTOCOL: Specify the wire protocol version to use
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ZeroMQ 3.x extended the pub-sub protocol to support subscription forwarding,
which isn't compatible with 2.x pub-sub semantics. The 'ZMQ_PROTOCOL' option
allows for specifying the protocol version to use. A value of `1` designates
backwards compatibility with existing 2.x pub-sub components in an existing
topology.

[horizontal]
Option value type:: int
Option value unit:: >0
Default value:: 0 (with subscription forwarding)
Applicable socket types:: all (only respected by ZMQ_PUB and ZMQ_SUB)

RETURN VALUE
------------
The _zmq_setsockopt()_ function shall return zero if successful. Otherwise it
Expand Down

0 comments on commit 0578ec8

Please sign in to comment.