/** * Cross-process exclusion lock for the daemon singleton. * * The lock is POSIX-only; on Windows the daemon's named-pipe path is * kernel-refcounted and provides cross-process exclusion natively, so * `acquireLock` skips this module on `process.platform === 'win32'`. */ export interface PidLock { release(): Promise; } /** * Attempt to claim the daemon's cross-process PID lock. * * Returns a {@link PidLock} on success, or `null` when another live * process already holds it. Throws on unrecoverable I/O errors * (`EACCES`, `ENOSPC`, missing WAL dir, etc.) — callers should treat * a throw as "daemon cannot start" rather than "concede to sibling." */ export declare function tryAcquirePidLock(): Promise; /** * Read the pid recorded in the daemon's lockfile, or `null` if the * file is missing or unparseable. Provided as a diagnostic helper for * callers (e.g. supervisor) that want to log "who owns the lock right * now"; not used by acquisition itself. */ export declare function readLockHolderPid(): Promise;