Expand description
atomr-cluster-tools.
src/contrib/cluster/.
Structs§
- AckHandle
- Handle handed back from
ClusterKillSwitch::register_guardedthat a party uses to acknowledge it has quiesced. - Cluster
Client - Cluster
Client Settings - Settings for a
ClusterClient. - Cluster
Kill Switch - Distributed emergency-halt latch. Cheap to clone via
Arc. - Cluster
PubSub - Mediator that augments a local
DistributedPubSubwith a cross-node topic table + transport. Clusters publish viaClusterPubSub::publish_remotewhich fans out to all nodes that have advertised the topic; receivers route the payload to local subscribers using the codec registry. - Cluster
Receptionist - Cluster
Singleton Manager - Decides which node hosts the singleton based on oldest up-member — a hook is provided so tests can simulate handover without wiring the full cluster.
- Cluster
Singleton Proxy - Proxy that routes messages to the current singleton, buffering during handover.
- Distributed
PubSub - Fence
Token - Monotonic fencing token (FR-7c). Bumped every time this node assumes
the singleton, so stale writers from a prior incarnation can be
rejected by comparing tokens.
Ordso the highest token wins. - Halt
Token - Token returned by
ClusterKillSwitch::engage, identifying the engage operation (monotonic, per-process). - Handoff
State - Opaque serialized external session carried across a handover.
- Kill
Switch Quorum Observer - Adapter wiring FR-7 → FR-5: a
QuorumObserverthat engages the kill switch when quorum is lost. Drop this intoSbrRuntime::with_observerto halt the node on partition loss. - Quiescence
Report - Result of
ClusterKillSwitch::await_quiescence. - Reset
Authorization - Two-person authorization required to
ClusterKillSwitch::reset.
Enums§
- Cluster
Client Error - HaltPdu
- Wire shape of a cross-node kill-switch exchange. Mirrors the
MediatorPdupattern used byClusterPubSub: an opaque, serializable message that aHaltTransportcarries to a peer and that the peer feeds back viaClusterKillSwitch::apply_pdu. - Halt
Reason - Why the kill switch was engaged. Recorded alongside the latch for post-incident analysis.
- Mediator
Pdu - Wire shape of a cross-node mediator exchange.
- Reset
Error - Error returned by
ClusterKillSwitch::resetwhen authorization is invalid. - Singleton
State - Singleton lifecycle state.
Traits§
- Halt
Guarded - A party that must be brought to a safe stop when the switch engages.
on_haltshould stop accepting new work and prepare to acknowledge quiescence; it must not block for long. - Halt
Transport - Pluggable transport for cross-node kill-switch fan-out. Sends a
HaltPduto a peer node identified by an opaque string node id (typicallyAddress::to_string()); the receiver feeds inbound PDUs back into its local switch viaClusterKillSwitch::apply_pdu. - Mediator
Transport - Pluggable transport for the cross-node mediator. Sends an outbound
MediatorPduto a peer node, identified by an opaque string node id (typicallyAddress::to_string()). The transport is responsible for the wire round-trip; on the receiver side, the inbound PDU is fed back into the local mediator viaClusterPubSub::apply_pdu. - Singleton
Handoff - Hook for migrating external state (e.g. a broker session, a lease, an open file) when the singleton moves between nodes (FR-7c).