Skip to main content

Module platform

Module platform 

Source

Structs§

LeadershipHandle
Handle returned by LeaderElector::start(). One-shot per LeaderElector instance — create a new instance to restart.
NoopLeaderElector
No-op leader elector — always wins leadership immediately. Correct for single-node deployments and tests that do not need real K8s.
NoopReadinessGate
No-op readiness gate — all calls are no-ops, never blocks.
PlatformIdentity
Node identity in the platform environment. In Kubernetes: pod name, namespace, labels from Downward API. In local/test: hostname or user-supplied string.

Enums§

LeadershipEvent
Leadership state change events delivered asynchronously.
PlatformError
Platform errors.

Traits§

LeaderElector
Leader election abstraction. The elector owns the renew loop — callers do not manage timers. One-shot: start() may only be called once per instance.
ReadinessGate
Readiness gate — local override that forces readiness state regardless of HealthSource. Name reflects actual role: a gate on local health state, not a push to external system.