HeartbeatConfig

data class HeartbeatConfig(val interval: Duration = 5.seconds, val timeout: Duration = 15.seconds, val reconnectWindow: Duration = 60.seconds, val resumeTimeout: Duration = timeout)

Configuration for HeartbeatPartitionDetector.

Defaults: 5 s ping interval, 15 s timeout, 60 s reconnect window, 15 s resume timeout. Override via RoomConfig when the application needs different timing — for example, a longer reconnectWindow for a long idle period.

Constructors

Link copied to clipboard
constructor(interval: Duration = 5.seconds, timeout: Duration = 15.seconds, reconnectWindow: Duration = 60.seconds, resumeTimeout: Duration = timeout)

Properties

Link copied to clipboard

How often the detector sends a ping frame to the peer.

Link copied to clipboard

How long after first becoming unresponsive before the peer is considered lost.

Link copied to clipboard

Deadline for one attempt of a joiner's reconnect: a Hello awaiting the host's Welcome or Reject. When it elapses with no verdict the attempt ends as timed out and the reconnect tries again, instead of parking. An attempt whose seam tears first ends at once, without waiting this out: no reply can come back over it.

Link copied to clipboard

How long without any inbound frame (ping or application) before the peer is considered unresponsive.