[zeromq-dev] CZMQ/ZMQ Heartbeating demo.

Luca Boccassi luca.boccassi at gmail.com
Thu Nov 9 21:14:00 CET 2017

On Thu, 2017-11-09 at 19:08 +0000, Stephen Gray wrote:
> We have built-in heartbeating socket options from libzmq 4.2.0.
> http://czmq.zeromq.org/czmq4-0:zsock
> Does anyone know of a demo code which shows how to use them? Ideally
> using CZMQ.
> In particular; how does a program break out of a long-running send or
> receive loop when the heartbeat ttl has expired or there in no
> heartbeat response from a peer?
> Thanks.

You can listen for events, in particular a disconnect one will happen
if a heartbeat fails.

Kind regards,
Luca Boccassi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20171109/2734b0cf/attachment.sig>

More information about the zeromq-dev mailing list