IControlPlane
Everything the mesh needs from the control plane: a node registry and container leases with epochs.
Nebula · Packages/com.1by3.nebula/Runtime/ControlPlane/IControlPlane.cspublic interface IControlPlane : IDisposableEverything the mesh needs from the control plane: a node registry and container leases with epochs. Low write volume, subscription push, never on the per-tick hot path. SpacetimeControlPlane is the real implementation; LocalControlPlane is in-process for tests and single-process runs. All callbacks fire on the main thread from Tick.
Properties
IsConnected
bool IsConnected { get; }Now
DateTime Now { get; }Best estimate of the control plane's clock (for heartbeat age checks).
Workers
IReadOnlyList<WorkerInfo> Workers { get; }Leases
IReadOnlyList<LeaseInfo> Leases { get; }Gateways
IReadOnlyList<GatewayInfo> Gateways { get; }Settings
IReadOnlyDictionary<string, string> Settings { get; }Mesh-wide live settings: string key/values Nebula attaches no meaning to. The orchestrator seeds them (-nebula-settings k=v,k=v), the dashboard edits them, and game code on a worker may write them. They are the game's low-volume coordination channel across workers (e.g. a spawn budget every worker reconciles against); never per-tick state.
Events
Changed
event Action Changed;Methods
Connect
void Connect();Tick
void Tick();RegisterWorker
void RegisterWorker(string workerId, uint workerIndex, string address, ushort port);HeartbeatWorker
void HeartbeatWorker(string workerId, string status, in WorkerStats stats);UnregisterWorker
void UnregisterWorker(string workerId);RegisterGateway
void RegisterGateway(string gatewayId, string address, ushort port);HeartbeatGateway
void HeartbeatGateway(string gatewayId);UnregisterGateway
void UnregisterGateway(string gatewayId);HeartbeatOrchestrator
void HeartbeatOrchestrator(string orchestratorId, uint desiredWorkers);SetSetting
void SetSetting(string key, string value);Set (or create) one mesh-wide setting. Every subscriber sees it through Changed.
EnsureContainer
void EnsureContainer(string containerId);AssignContainer
void AssignContainer(string containerId, string workerId);SetLeaseState
void SetLeaseState(string containerId, string state);ReleaseContainer
void ReleaseContainer(string containerId);ResetControlPlane
void ResetControlPlane();