Skip to main content
Cluster.emit - node__cluster.d.ts - Node documentation
method Cluster.emit

Usage in Deno

```typescript import { type Cluster } from "node:node__cluster.d.ts"; ```
Cluster.emit(
event: string | symbol,
...args: any[],
): boolean

Parameters

event: string | symbol
...args: any[]

Return Type

boolean
Cluster.emit(
event: "disconnect",
worker: Worker,
): boolean

Parameters

event: "disconnect"
worker: Worker

Return Type

boolean
Cluster.emit(
event: "exit",
worker: Worker,
code: number,
signal: string,
): boolean

Parameters

event: "exit"
worker: Worker
code: number
signal: string

Return Type

boolean
Cluster.emit(
event: "fork",
worker: Worker,
): boolean

Parameters

event: "fork"
worker: Worker

Return Type

boolean
Cluster.emit(
event: "listening",
worker: Worker,
address: Address,
): boolean

Parameters

event: "listening"
worker: Worker
address: Address

Return Type

boolean
Cluster.emit(
event: "message",
worker: Worker,
message: any,
handle: net.Socket | net.Server,
): boolean

Parameters

event: "message"
worker: Worker
message: any
handle: net.Socket | net.Server

Return Type

boolean
Cluster.emit(
event: "online",
worker: Worker,
): boolean

Parameters

event: "online"
worker: Worker

Return Type

boolean
Cluster.emit(
event: "setup",
settings: ClusterSettings,
): boolean

Parameters

event: "setup"
settings: ClusterSettings

Return Type

boolean