/** * In-process signal receipt log (crew#411). * * Node's `process.on('SIGTERM'/'SIGINT')` callbacks receive no sender pid — * there is no SA_SIGINFO equivalent in the JS runtime. The best-effort record * is therefore: signal name + epoch-ms timestamp. * * The log is read by `SeatHealthTracker` when an ACP bridge dies silently * (`acpFallback` with `fallbackKind: session_died`) to distinguish: * * - "daemon also received SIGTERM at T" → likely a group/terminal signal that * killed both the bridge and the daemon together * - "no daemon signal within ±5s" → a pid-targeted external signal sent * directly to the bridge, or a transport close (neither woke the daemon) * * The ring is bounded (64 entries) because signals are rare and the entries are * tiny; the oldest entry is dropped once the cap is exceeded. */ export interface SignalEntry { signal: 'SIGTERM' | 'SIGINT'; at: number; } /** Half-width of the default correlation window used by `findInWindow`. */ export declare const SIGNAL_CORRELATION_WINDOW_MS = 5000; export declare class DaemonSignalLog { private readonly _entries; private static readonly MAX; /** * Append a signal receipt. `at` defaults to `Date.now()`; injectable so tests * can set exact timestamps without mocking the clock process-wide. */ record(signal: 'SIGTERM' | 'SIGINT', at?: number): void; /** * Return the closest entry within [`aroundMs` ± `halfWindowMs`], or * `undefined` when no entry falls in that interval. * `halfWindowMs` defaults to `SIGNAL_CORRELATION_WINDOW_MS` (5 s). */ findInWindow(aroundMs: number, halfWindowMs?: number): SignalEntry | undefined; /** All recorded entries, oldest first — a defensive copy, so a caller cannot mutate the ring. */ entries(): readonly SignalEntry[]; } /** The daemon-wide singleton. The CLI records into it; the seat-health tracker reads from it. */ export declare const daemonSignalLog: DaemonSignalLog; //# sourceMappingURL=daemon-signal-log.d.ts.map