LeaderOptions
Deliberately extends CommonOptions, not BusOptions: heartbeatMs here means
the leader’s re-announce interval, which is a different thing from the bus’s
presence ping. See the note in leader.ts about forwarding to getBus.
Extends
Section titled “Extends”Properties
Section titled “Properties”eligible?
Section titled “eligible?”optional eligible?: boolean;May this client hold the leadership? Default true.
heartbeatMs?
Section titled “heartbeatMs?”optional heartbeatMs?: number;How often the leader re-announces itself, in ms. Default 1000.
optional kind?: PeerKind;What this client announces itself as. Defaults to ‘worker’ when there is no document, else ‘tab’.
Inherited from
Section titled “Inherited from”leaseMs?
Section titled “leaseMs?”optional leaseMs?: number;How long a follower tolerates silence before calling the seat empty, in ms. Default 3000.
transport?
Section titled “transport?”optional transport?: (name) => Transport;Transport factory, mainly for tests. Defaults to defaultTransport.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
name | string |