/**
 * 孤儿进程监控服务
 *
 * 定期扫描和检测孤儿进程，支持自动清理和告警
 */
/**
 * 孤儿进程事件类型
 */
export type OrphanEventType = 'orphan_detected' | 'orphan_cleaned' | 'process_unresponsive' | 'process_high_cpu' | 'process_high_memory' | 'health_check';
/**
 * 孤儿进程事件
 */
export interface OrphanEvent {
    type: OrphanEventType;
    agentId: string;
    pid?: number;
    message: string;
    timestamp: Date;
    details?: Record<string, unknown>;
}
/**
 * 孤儿进程监控器
 */
export declare class OrphanMonitor {
    private intervalId;
    private lastScanTime;
    private eventListeners;
    private stopped;
    /**
     * 启动监控器
     */
    start(): Promise<void>;
    /**
     * 停止监控器
     */
    stop(): void;
    /**
     * 执行一次扫描
     */
    scan(): Promise<void>;
    /**
     * 处理检测到的孤儿进程
     */
    private handleOrphanDetected;
    /**
     * 处理健康异常
     */
    private handleHealthIssue;
    /**
     * 自动清理孤儿进程
     */
    private autoCleanOrphan;
    /**
     * 清理已死亡的会话记录
     */
    private cleanupDeadSessions;
    /**
     * 上报事件到调度中心
     */
    private reportToScheduler;
    /**
     * 注册事件监听器
     */
    onEvent(listener: (event: OrphanEvent) => void): void;
    /**
     * 移除事件监听器
     */
    offEvent(listener: (event: OrphanEvent) => void): void;
    /**
     * 触发事件
     */
    private emit;
    /**
     * 获取监控状态
     */
    getStatus(): {
        running: boolean;
        lastScanTime: Date | null;
        mode: string;
    };
}
/**
 * 获取孤儿进程监控器实例
 */
export declare function getOrphanMonitor(): OrphanMonitor;
/**
 * 启动孤儿进程监控
 */
export declare function startOrphanMonitor(): Promise<void>;
/**
 * 停止孤儿进程监控
 */
export declare function stopOrphanMonitor(): void;
//# sourceMappingURL=orphan-monitor.d.ts.map