Hi, @there,

Following is the issue we encountered in our production env:

We are using ZeroMQ PUB/SUB pattern, 
but the weird thing is that at the SUB  end, netstat showed the zeromq socket 
is in ESTABLISHED state, 
while at the PUB end, the LISTEN socket is still there, but the corresponding 
ESTABLISHED socket disappeared.
Given there is not built-in hearbeat mechanism in ZeroMQ, 
for such situation, what's the best practice to leverage TCP keepalive to 
dectect this issue?

So...at the SUB end, if I set ZMQ_TCP_KEEPALIVE/ZMQ_TCP_KEEPALIVE_IDLE 
properly, 
* if I choose to use czmq, how can I assert the socket is dead thru the 
zstr_recv()?
* if use libzmq directly, how can I do the same thing by zmq_msg_recv()?

Regards,
Meng

_______________________________________________
zeromq-dev mailing list
[email protected]
http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Reply via email to