Context
RetryQueue retries with exponential backoff indefinitely. During prolonged outages, this wastes resources without fast-failing.
Goal
Circuit breaker state ("open") to fast-fail after sustained failures, with automatic recovery attempt after a cooldown period.
Implementation
- Track consecutive failure count
- Open circuit after N consecutive failures
- Reject immediately while circuit is open
- After cooldown, allow one probe request (half-open)
- Success closes circuit, failure reopens
Files
src/network/RetryQueue.ts
tests/network/RetryQueue.test.ts
Source: AUDIT4 (-1 Defense-in-Depth)
Context
RetryQueue retries with exponential backoff indefinitely. During prolonged outages, this wastes resources without fast-failing.
Goal
Circuit breaker state ("open") to fast-fail after sustained failures, with automatic recovery attempt after a cooldown period.
Implementation
Files
src/network/RetryQueue.tstests/network/RetryQueue.test.tsSource: AUDIT4 (-1 Defense-in-Depth)