CircuitSnapshot
Defined in: src/queue/circuit-breaker.ts:18
Point-in-time view of one partition’s circuit breaker, as returned by
client.circuits(). A plain copy: mutating it doesn’t affect the breaker.
Properties
Section titled “Properties”partition
Section titled “partition”partition:
string
Defined in: src/queue/circuit-breaker.ts:19
state:
"closed"|"open"|"half_open"
Defined in: src/queue/circuit-breaker.ts:22
An open circuit whose nextAttemptAt has passed stays open until
the next request arrives; that request is admitted as the half-open trial.
failures
Section titled “failures”failures:
number
Defined in: src/queue/circuit-breaker.ts:24
Consecutive failures, or failures in the rolling window when window is set.
openedAt?
Section titled “openedAt?”
optionalopenedAt?:number
Defined in: src/queue/circuit-breaker.ts:26
Epoch ms when the circuit last opened. Absent while closed.
nextAttemptAt?
Section titled “nextAttemptAt?”
optionalnextAttemptAt?:number
Defined in: src/queue/circuit-breaker.ts:28
Epoch ms when an open circuit admits its next trial (openedAt + resetTimeoutMs). Absent while closed.
