export type ClusterWorkerCount = 'auto' | number; export interface ClusterEvent { type: 'primary:start' | 'worker:exit' | 'cluster:shutdown' | 'cluster:error'; level: 'info' | 'warn' | 'error'; message: string; } export interface RunClusterOptions { /** Number of workers, or the host's available parallelism. Default: `auto`. */ workers?: ClusterWorkerCount; /** Maximum time workers get to stop after a shutdown signal. Default: 30 seconds. */ shutdownTimeoutMs?: number; /** Receives early lifecycle events before the application logger exists. */ onEvent?(event: ClusterEvent): void; } /** Run `startWorker` only in Node cluster workers; the primary supervises them. */ export declare function runCluster(startWorker: () => void | Promise, options?: RunClusterOptions): Promise;