You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The description of ZMQ_RECONNECT_STOP_AFTER_DISCONNECT in the zeromq documentation is:
The 'ZMQ_RECONNECT_STOP_AFTER_DISCONNECT' option will stop reconnection when
zmq_disconnect() has been called. This can be useful when the user's request failed
(server not ready), as the socket does not need to continue to reconnect after
user disconnect actively. (https://zeromq.github.io/libzmq/zmq_setsockopt.html)
However, in actual testing, I found that after the socket set the ZMQ_RECONNECT_STOP_AFTER_DISCONNECT option, there is a probability that the reconnection will be abandoned before calling zmq_disconnect.
For the test code above, we expect to see output like this:
Got event: CLOSED
Got event: CONNECT_RETRIED
Got event: CLOSED
Got event: CONNECT_RETRIED
Got event: CLOSED
Got event: CONNECT_RETRIED
Got event: CLOSED
Got event: CONNECT_RETRIED
Got event: CLOSED
Got event: CLOSED
Still waiting for monitor event after 250 ms
Still waiting for monitor event after 500 ms
Still waiting for monitor event after 750 ms
Still waiting for monitor event after 1000 ms
When this problem occurs, the output is like this:
Got event: CLOSED
Still waiting for monitor event after 250 ms
Still waiting for monitor event after 500 ms
Still waiting for monitor event after 750 ms
Still waiting for monitor event after 1000 ms
The text was updated successfully, but these errors were encountered:
Issue description
The description of
ZMQ_RECONNECT_STOP_AFTER_DISCONNECT
in the zeromq documentation is:The 'ZMQ_RECONNECT_STOP_AFTER_DISCONNECT' option will stop reconnection when
zmq_disconnect() has been called. This can be useful when the user's request failed
(server not ready), as the socket does not need to continue to reconnect after
user disconnect actively. (https://zeromq.github.io/libzmq/zmq_setsockopt.html)
However, in actual testing, I found that after the socket set the
ZMQ_RECONNECT_STOP_AFTER_DISCONNECT
option, there is a probability that the reconnection will be abandoned before callingzmq_disconnect
.For the test code above, we expect to see output like this:
When this problem occurs, the output is like this:
The text was updated successfully, but these errors were encountered: