NOTE

Application Heartbeats

Heartbeat design for detecting stale connections and distinguishing liveness from end-to-end health.

JavaCreated Updated 1 min readhistorical

This is a historical learning note and may contain outdated or incomplete understanding.

An application heartbeat sends periodic liveness traffic so peers can detect silent/stale connections sooner than very long transport/network timeouts.

Choose interval and failure threshold based on detection requirements and false-positive tolerance. Network pauses, GC/scheduling delays, mobile sleep, or temporary packet loss can delay heartbeats, so one missed heartbeat should not automatically imply permanent failure.

TCP keepalive and application heartbeats solve related but different problems. A successful transport heartbeat also does not prove the remote business dependency is healthy.

Loading helpful count