import * as express from 'express';
import { Server } from 'http';
import * as WebSocket from 'ws';
import { CronManager } from './managers/cron.manager';
import { MethodManager } from './managers/method.manager';
import { MonitorManager } from './managers/monitor.manager';
import { SubscriptionManager } from './managers/subscription.manager';
import { WebSocketManager } from './managers/websocket.manager';
import { WorkerDispatcherManager } from './managers/worker-dispatcher.manager';
import { WorkerServerManager } from './managers/worker-server.manager';
export declare class ResolveIOMainServer {
    private _app;
    private _serverHTTP;
    private _portHTTP;
    private _serverWSS;
    private _offlineUpdates;
    sesMail: boolean;
    private publicProgram;
    private _rebootFlag;
    private LOGGER;
    private _websocketManager;
    private _monitorManager;
    private _monitorManagerFunction;
    private _subscriptionManager;
    private _methodManager;
    private _cronManager;
    private _clientRoutes;
    private _workerDispatcherManager;
    private _workerServerManager;
    private _aiAssistantCodexManager;
    private _httpServerClosePromise;
    private _websocketServerClosePromise;
    private _wsConnectDebug;
    private _perfDebug;
    private _perfDebugIntervalMs;
    private _perfDebugTimer;
    private _perfDebugLastCpu;
    private _perfDebugLastTs;
    private _eventLoopHistogram;
    private _cpuProfileOnStart;
    private _cpuProfileAuto;
    private _cpuProfileDurationMs;
    private _cpuProfileThresholdPct;
    private _cpuProfileTriggerCount;
    private _cpuProfileHighCount;
    private _cpuProfileDir;
    private _cpuProfileSession;
    private _timerDebug;
    private _timerDebugThresholdMs;
    private _timerDebugMinDelayMs;
    private _timerDebugSampleRate;
    private _timerDebugLogLimit;
    private _timerDebugLogCount;
    private _aiWorkerDebug;
    private _standaloneNodeReaperEnabled;
    private _standaloneNodeReaperIntervalMs;
    private _standaloneNodeReaperMinAgeSeconds;
    private _standaloneNodeReaperMaxKillsPerSignature;
    private _standaloneNodeReaperKillWindowMs;
    private _standaloneNodeReaperIncludeSystemdServices;
    private _standaloneNodeReaperHighCpuPct;
    private _standaloneNodeReaperHighRssMb;
    private _standaloneNodeReaperHighMinAgeSeconds;
    private _standaloneNodeReaperHighConsecutiveScans;
    private _standaloneNodeReaperDryRun;
    private _standaloneNodeReaperAlertWindowMs;
    private _standaloneNodeReaperTimer;
    private _standaloneNodeReaperRunning;
    private _standaloneNodeReaperKillCounts;
    private _standaloneNodeReaperSuppressedSignatures;
    private _standaloneNodeReaperResourceHits;
    private _standaloneNodeReaperAlertTimes;
    private _serverStartTime;
    private _lastErrorMsg;
    private _debugMsgRecv;
    private _debugMsgQueue;
    private _isWorkersEnabled;
    private _isWorkerInstance;
    private _safeShutdown;
    private _dynamicAppGatewayEnabled;
    private _dynamicAppGatewayCache;
    private _socketTier;
    private _maxClientSockets;
    private _singleIpPerUser;
    private _socketPolicyUpgradeUrl;
    private readonly _clientHeartbeatIntervalMs;
    private readonly _clientHeartbeatInitialDelayMs;
    private readonly _clientHeartbeatBackpressureBytes;
    private readonly _dynamicAppGatewayCacheMs;
    constructor();
    static create(): Promise<ResolveIOMainServer>;
    private initialize;
    private startAiAssistantCodexManagerIfEnabled;
    private startStandaloneNodeReaper;
    private reapStandaloneNodeProcesses;
    private createStandaloneNodeReaperDetails;
    private reportStandaloneNodeReaperAction;
    private listSystemProcesses;
    private parseProcessSnapshot;
    private execFileText;
    private resolvePm2ProtectedPids;
    private shouldReapStandaloneNodeProcess;
    private resolveStandaloneNodeReaperReason;
    private isNodeProcess;
    private isResolveIOAppProcess;
    private hasHighStandaloneNodeResourceUsage;
    private recordStandaloneNodeResourceHit;
    private clearStandaloneNodeResourceHit;
    private resolveStandaloneNodeProcessSignature;
    private canReapStandaloneNodeSignature;
    private recordStandaloneNodeReaperKill;
    private logStandaloneNodeReaperSuppressed;
    private resolveCurrentAppDirs;
    private resolveProcessCwd;
    private safeRealpath;
    private isSameUidProcess;
    private isProtectedSystemdServiceProcess;
    private resolveSystemdServiceName;
    private shutdownNetworkServers;
    private closeHttpServerGracefully;
    private closeWebSocketServerGracefully;
    private startServerInstance;
    private installDynamicAppGatewayMiddleware;
    private resolveDynamicAppGatewayEnabled;
    private extractDynamicAppGatewayId;
    private resolveDynamicAppGatewayToken;
    private normalizeHeaderValue;
    private normalizeHostname;
    private resolveOriginHostname;
    private isLocalHostname;
    private resolveDynamicAppControlHosts;
    private resolveDynamicAppAllowedHosts;
    private applyDynamicAppGatewayCorsHeaders;
    private resolveCachedDynamicAppGatewayApp;
    private safeShutdown;
    getIsWorkersEnabled(): boolean;
    getIsWorkerInstance(): boolean;
    getWSList(): any[];
    getWSUserList(): any[];
    getHTTPServer(): Server<typeof import("http").IncomingMessage, typeof import("http").ServerResponse>;
    getCronManager(): CronManager;
    private reportServerError;
    getMethodManager(): MethodManager;
    getSubscriptionManager(): SubscriptionManager;
    getMonitorManager(): MonitorManager;
    getRebootFlag(): boolean;
    getWebSocketManager(): WebSocketManager;
    private createServer;
    /**
     * Listen for connections from clients or workers.
     */
    private listen;
    private processSocketMessage;
    private decodeBufferPayload;
    private parseTextFallback;
    private looksLikeTextPayload;
    private resolveConnectDebug;
    private resolvePerfDebug;
    private resolveCpuProfileOnStart;
    private resolveCpuProfileAuto;
    private resolveCpuProfileDurationMs;
    private resolveCpuProfileThresholdPct;
    private resolveCpuProfileTriggerCount;
    private resolveCpuProfileDir;
    private resolveTimerDebug;
    private resolveTimerDebugThresholdMs;
    private resolveTimerDebugMinDelayMs;
    private resolveTimerDebugSampleRate;
    private resolveTimerDebugLogLimit;
    private resolveStandaloneNodeReaperEnabled;
    private resolveStandaloneNodeReaperIntervalMs;
    private resolveStandaloneNodeReaperMinAgeSeconds;
    private resolveStandaloneNodeReaperMaxKillsPerSignature;
    private resolveStandaloneNodeReaperKillWindowMs;
    private resolveStandaloneNodeReaperIncludeSystemdServices;
    private resolveStandaloneNodeReaperHighCpuPct;
    private resolveStandaloneNodeReaperHighRssMb;
    private resolveStandaloneNodeReaperHighMinAgeSeconds;
    private resolveStandaloneNodeReaperHighConsecutiveScans;
    private resolveStandaloneNodeReaperDryRun;
    private resolveStandaloneNodeReaperAlertWindowMs;
    private isPm2ManagedRuntime;
    private isPrimaryPm2Instance;
    private isLocalRuntime;
    private normalizeWorkerSelectorValue;
    private shouldStartCronManagerForWorker;
    private parseWorkerSelector;
    private workerMatchesSelector;
    private resolveWorkerRole;
    private parsePositiveInt;
    private parsePositiveFloat;
    private startPerfDebug;
    private installTimerDebug;
    private startCpuProfile;
    private stopCpuProfile;
    private resolveWritableProfileDir;
    private parseDebugFlag;
    private parseOptionalBoolean;
    private parseNonNegativeInt;
    private resolveSocketTier;
    private resolveSocketTierKeySuffix;
    private resolveMaxClientSockets;
    private resolveSingleIpPerUserPolicy;
    private resolveSocketPolicyUpgradeUrl;
    private resolveSocketUpgradeUrlWithAppId;
    private normalizeIpAddress;
    private resolveClientIp;
    private buildSocketLimitMessage;
    private buildSocketLimitCloseReason;
    private disconnectUserSocketsFromDifferentIps;
    private evaluateClientSocketAdmission;
    private logConnectDebug;
    private triggerClientHeartbeat;
    private shouldDeferHeartbeat;
    private handleClientMessage;
    /**
     * callMethodLocally is your old approach for invoking the method in-process.
     */
    private callMethodLocally;
    /**
     * Cleanly remove a client from the subscription manager, etc.
     */
    unsubscribeWS(ws: WebSocket): Promise<void>;
    getApp(): express.Application;
    getServerConfig(): any;
    getWorkerDispatcherManager(): WorkerDispatcherManager;
    getWorkerServerManager(): WorkerServerManager;
}
