Interface IClusterCoordinator

Assembly: redb.Tsak.Core.Pro.dll

Main cluster coordination service.
Orchestrates node registration, heartbeat, leader election, and assignment polling.
Runs as a background loop on every cluster-enabled node.

public interface IClusterCoordinator

Properties

CurrentEpoch

Current leader epoch (for fencing stale operations).

long CurrentEpoch { get; }

IsLeader

Whether this node is currently the cluster leader.

bool IsLeader { get; }

NodeId

Unique identifier of this node.

string NodeId { get; }

Methods

RebalanceAsync(CancellationToken)

Triggers an immediate rebalance (used by API or topology changes).

Task RebalanceAsync(CancellationToken ct = default)

StartAsync(CancellationToken)

Starts the cluster coordination loop.

Task StartAsync(CancellationToken ct = default)

StopAsync(CancellationToken)

Stops the cluster coordination loop and deregisters the node.

Task StopAsync(CancellationToken ct = default)