summaryrefslogtreecommitdiff
path: root/doc/zmq_setsockopt.txt
diff options
context:
space:
mode:
Diffstat (limited to 'doc/zmq_setsockopt.txt')
-rw-r--r--doc/zmq_setsockopt.txt50
1 files changed, 47 insertions, 3 deletions
diff --git a/doc/zmq_setsockopt.txt b/doc/zmq_setsockopt.txt
index 1b551c6..af92929 100644
--- a/doc/zmq_setsockopt.txt
+++ b/doc/zmq_setsockopt.txt
@@ -87,7 +87,7 @@ Applicable socket types:: N/A
ZMQ_IDENTITY: Set socket identity
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The 'ZMQ_IDENTITY' option shall set the identity of the specified 'socket'.
-Socket identity determines if existing 0MQ infastructure (_message queues_,
+Socket identity determines if existing 0MQ infrastructure (_message queues_,
_forwarding devices_) shall be identified with a specific application and
persist across multiple runs of the application.
@@ -115,7 +115,7 @@ therefore you should call this option to establish an initial message filter.
An empty 'option_value' of length zero shall subscribe to all incoming
messages. A non-empty 'option_value' shall subscribe to all messages beginning
-with the specified prefix. Mutiple filters may be attached to a single
+with the specified prefix. Multiple filters may be attached to a single
'ZMQ_SUB' socket, in which case a message shall be accepted if it matches at
least one filter.
@@ -160,7 +160,7 @@ transports using the specified 'socket'. The recovery interval determines the
maximum time in seconds that a receiver can be absent from a multicast group
before unrecoverable data loss will occur.
-CAUTION: Excersize care when setting large recovery intervals as the data
+CAUTION: Exercise care when setting large recovery intervals as the data
needed for recovery will be held in memory. For example, a 1 minute recovery
interval at a data rate of 1Gbps requires a 7GB in-memory buffer.
@@ -216,6 +216,48 @@ Default value:: 0
Applicable socket types:: all
+ZMQ_LINGER: Set linger period for socket shutdown
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+The 'ZMQ_LINGER' option shall be set to specify period for pending outbound
+messages to linger in memory after closing the socket. Value of -1 means
+infinite. Pending messages will be kept until they are fully transferred to
+the peer. Value of 0 means that all the pending messages are dropped immediately
+when socket is closed. Positive value means number of milliseconds to keep
+trying to send the pending messages before discarding them.
+
+[horizontal]
+Option value type:: int
+Option value unit:: milliseconds
+Default value:: -1
+Applicable socket types:: all
+
+
+ZMQ_RECONNECT_IVL: Set reconnect period for connection-based transports
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+The 'ZMQ_RECONNECT_IVL' option shall be set to specify how long it takes for a
+disconnected underlying connection to attempt to reconnect. The interval
+can be randomized to some extent by 0MQ to prevent reconnection storms.
+
+[horizontal]
+Option value type:: int
+Option value unit:: milliseconds
+Default value:: 100
+Applicable socket types:: all
+
+
+ZMQ_BACKLOG: Set maximum length of the queue of pending connections
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+The 'ZMQ_BACKLOG' option shall be set to specify maximum size of the
+pending connection backlog for connection-based transports. For details
+refer to your operating system documentation for the 'listen' function.
+
+[horizontal]
+Option value type:: int
+Option value unit:: connections
+Default value:: 100
+Applicable socket types:: all
+
+
RETURN VALUE
------------
The _zmq_setsockopt()_ function shall return zero if successful. Otherwise it
@@ -231,6 +273,8 @@ _option_value_ is invalid.
The 0MQ 'context' associated with the specified 'socket' was terminated.
*EFAULT*::
The provided 'socket' was not valid (NULL).
+*EINTR*::
+The operation was interrupted by delivery of a signal.
EXAMPLE