Skip to main content
Version: Next

LoadSignal

A signal that reports whether a particular resource is overloaded.

SystemStatus aggregates multiple LoadSignal instances to determine overall system health. The built-in signals cover memory, CPU, event loop, and API client rate limits. You can implement this interface to add custom overload signals (e.g. navigation timeouts, proxy health).

Implemented by

Index

Properties

readonlyname

name: string

Human-readable name used in logging and SystemInfo keys.

readonlyoverloadedRatio

overloadedRatio: number

Maximum ratio of overloaded snapshots in a sample before the signal is considered overloaded. For example, 0.2 means the signal fires when more than 20% of the sample window is overloaded.

Methods

getSample

  • Return snapshots for a recent time window (used for "current" status).


    Parameters

    • optionalsampleDurationMillis: number

      How far back to look, in milliseconds.

    Returns LoadSnapshot[]

start

  • start(): Promise<void>
  • Start collecting snapshots. Called when the pool starts.


    Returns Promise<void>

stop

  • stop(): Promise<void>
  • Stop collecting snapshots. Called when the pool shuts down.


    Returns Promise<void>