import type { NodePorts } from './types.js'; /** * Persisted record for a single managed child. The orchestrator mirrors its * in-memory map to disk so that cadre-host can re-attach to surviving * children after a restart. */ export interface PersistedHandle { containerId: string; dockerId: string; pid: number; startupToken: string; workdir: string; ports: NodePorts; spawnedAt: string; partyId: string; profile: 'storage' | 'transaction'; /** The public addresses the child was started announcing. Absent in a file written before they existed. */ announcedAddrs?: string[]; } export interface PersistedState { version: 1; handles: PersistedHandle[]; } /** JSON state file at `/state.json`, written atomically. */ export declare class StateStore { private readonly path; constructor(rootDir: string); load(): PersistedState; save(state: PersistedState): void; filePath(): string; }