I'm using NNG as my inter-server msg-queue.
Background:
- I'm implementing a pair of long time background services, those are communicating with NNG;
- Protocol: pair0 @ tcp;
- The payload message occurs maybe a second, or maybe a day;
My question: Does NNG automatically transmit a "Heartbeat" msg peroidically to each peer to keep the TCP connection alive, if there is no producing msg for a specific time duration?
If NOT, should I do "HeartBeat" by myself?
BTW, this is the first time I use NNG. I don't know whether there is a official/populated support forum of it, so I ask my question here.
Welcome to the NNG & distributed-processing
We can, under any circumstances send zero-sized "app-level" heartbeats, if we wish our transport be rock solid proven to be RTO
Yet, the NNG uses
nn_setsockopt()
-configurator options{ ... | NN_RECONNECT_IVL | NN_RECONNECT_IVL_MAX | ... }
to fine-tune low-level details, including the failed / closed sockets' reconnect managementThe full call signature is :
and a few details on
NN_RECONNECT_*
-s :