mirror of
https://github.com/zeromq/libzmq.git
synced 2024-12-12 18:40:27 +01:00
changed option name. +documentation changes
This commit is contained in:
parent
aec989fb5d
commit
f805e4dd03
@ -421,19 +421,21 @@ Default value:: 0
|
||||
Applicable socket types:: ZMQ_ROUTER
|
||||
|
||||
|
||||
ZMQ_PROBE_NEW_PEERS: automatically send empty packet to every established connection
|
||||
ZMQ_PROBE: automatically send empty packet to every established connection
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Sets the 'ROUTER' & 'DEALER' sockets behavior to automatically send an empty packet
|
||||
Sets the compatible sockets behavior to automatically send an empty packet
|
||||
to any new connection made (or accepted) by socket. It could help sockets to
|
||||
auto discovery themself. It especially important in 'ROUTER' <-> 'ROUTER' connections
|
||||
auto discovery them-self. It especially important in 'ROUTER' <-> 'ROUTER' connections
|
||||
where it solves 'who will write first' problems.
|
||||
NOTE: Don't set this options for sockets working with ZMQ_REP, ZMQ_REQ sockets.
|
||||
It will interfere with their strict synchronous logic and framing.
|
||||
|
||||
[horizontal]
|
||||
Option value type:: int
|
||||
Option value unit:: 0, 1
|
||||
Default value:: 0
|
||||
Applicable socket types:: ZMQ_ROUTER, ZMQ_DEALER
|
||||
Applicable socket types:: ZMQ_ROUTER, ZMQ_DEALER, ZMQ_REP, ZMQ_REQ
|
||||
|
||||
|
||||
ZMQ_XPUB_VERBOSE: provide all subscription messages on XPUB sockets
|
||||
|
@ -274,7 +274,7 @@ ZMQ_EXPORT int zmq_msg_set (zmq_msg_t *msg, int option, int optval);
|
||||
#define ZMQ_CURVE_SERVER 47
|
||||
#define ZMQ_CURVE_PUBLICKEY 48
|
||||
#define ZMQ_CURVE_SERVERKEY 49
|
||||
#define ZMQ_PROBE_NEW_PEERS 50
|
||||
#define ZMQ_PROBE 50
|
||||
|
||||
/* Message options */
|
||||
#define ZMQ_MORE 1
|
||||
|
@ -65,7 +65,7 @@ int zmq::dealer_t::xsetsockopt (int option_, const void *optval_,
|
||||
int value = is_int? *((int *) optval_): 0;
|
||||
|
||||
switch (option_) {
|
||||
case ZMQ_PROBE_NEW_PEERS:
|
||||
case ZMQ_PROBE:
|
||||
if (is_int && value >= 0) {
|
||||
probe_new_peers = value;
|
||||
return 0;
|
||||
|
@ -95,7 +95,7 @@ int zmq::router_t::xsetsockopt (int option_, const void *optval_,
|
||||
printf ("E: invalid option value (int=%d value=%d)\n", is_int, value);
|
||||
break;
|
||||
|
||||
case ZMQ_PROBE_NEW_PEERS:
|
||||
case ZMQ_PROBE:
|
||||
if (is_int && value >= 0) {
|
||||
probe_new_peers = value;
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user