Removes a node from the registry.
The id of the node to remove.
Returns a snapshot of the currently live nodes.
The live nodes; expired entries are pruned before the snapshot is taken.
Registers (or refreshes) a node with a heartbeat lifetime.
The node to register.
Lifetime in milliseconds; the node is considered gone if not refreshed within this window.
Subscribes to membership changes.
Invoked with the full set of live nodes whenever membership changes.
A function that cancels the subscription when called.
Registry of the nodes currently forming a cluster.
Remarks
Membership lets components discover peers, register themselves with a heartbeat TTL, and react to nodes joining or leaving. The default in-process implementation is MemoryMembership;
GossipMembershipprovides a decentralized, gossip-based implementation for multi-node deployments. Pair withMembershipReconcilerto turn membership snapshots into add/remove/update callbacks.