@eggjs/cluster
Version:
cluster manager for egg
22 lines (20 loc) • 912 B
TypeScript
import { ClusterHTTPSSecureOptions, ClusterOptions, ClusterStartMode } from "./utils/options.js";
import { Master, MasterOptions } from "./master.js";
import { ClusterAgentWorkerError } from "./error/ClusterAgentWorkerError.js";
import { ClusterWorkerExceptionError } from "./error/ClusterWorkerExceptionError.js";
//#region src/index.d.ts
/**
* cluster start flow:
*
* [startCluster] -> master -> agent_worker -> new [Agent] -> agentWorkerLoader
* `-> app_worker -> new [Application] -> appWorkerLoader
*
*/
/**
* start egg app
* @function Egg#startCluster
* @param {Object} options {@link Master}
*/
declare function startCluster(options: ClusterOptions): Promise<void>;
//#endregion
export { ClusterAgentWorkerError, type ClusterHTTPSSecureOptions, type ClusterOptions, type ClusterStartMode, ClusterWorkerExceptionError, Master, type MasterOptions, startCluster };