interface BlockedReport {
    cause: LoopStallCause;
    cpuScope: LoopCpuScope;
    cpuTime: number;
    duration: number;
    endedAt: number;
    gcTime: number;
    location?: string;
    severity: LoopMonitorSeverity;
    stack?: string;
    startedAt: number;
    warnThreshold: number;
    watchdogGap: number;
    windowStart: number;
}

Properties

host when the whole process stopped running (host CPU contention, a container CPU quota, a suspended machine) rather than code blocking the loop. Without a watchdog every stall is attributed to code.

cpuScope: LoopCpuScope

What cpuTime covers.

cpuTime: number

CPU consumed during the stall, in milliseconds. Scoped to the event-loop thread where Node offers process.threadCpuUsage() (22.15 / 23.9 and later); process-wide before that, which also counts the libuv pool and the native media threads and can exceed the stall duration.

duration: number

Heartbeat lag in milliseconds.

endedAt: number

When the loop ran again (the late heartbeat), epoch ms.

gcTime: number

Garbage-collection pause time observed during the stall, in milliseconds. Node delivers GC entries to observers a couple of loop turns after the fact, so a report is emitted one heartbeat after its stall to include them.

location?: string

The innermost frame of the agent's own code in the last sample, for the log line.

stack?: string

Sampled stacks of the loop thread during the stall, formatted like the Python monitor's: one block per sample (# loop thread sampled Nms into the stall then the innermost frames), blocks joined by \n---\n; or a one-line note saying why there is none. Absent for host-caused stalls and when sampling is off.

startedAt: number

Approximate wall-clock start in milliseconds since the Unix epoch.

warnThreshold: number
watchdogGap: number

How late the watchdog thread woke during the stall, in milliseconds. 0 without a watchdog.

windowStart: number

The last on-time heartbeat before the block, epoch ms: the block began within one tick after it.