checkId: check.servicegraph.circuitbreaker plugin: stellaops.doctor.servicegraph severity: warn tags: [servicegraph, resilience, circuit-breaker, live-state]

Circuit Breaker Status

This Doctor check reports the live circuit-breaker state exposed by the local resilience registry. It keeps threshold sanity checks as secondary evidence, but a green result now requires live state: configuration alone is not treated as proof that dependencies are healthy.

What It Checks

Reads live breaker snapshots through the read-only ICircuitBreakerStateProvider seam. Evidence includes open, half-open, and closed dependency counts plus retry and backoff counters. It also records Resilience:Enabled, BreakDurationSeconds, FailureThreshold, and SamplingDurationSeconds for threshold review.

ConditionResult
No live state provider, provider unavailable, or no breakers reportedskip
Any dependency breaker is openfail
Any dependency breaker is half-openwarn
Live breakers are closed but thresholds are too aggressivewarn
Live breakers are closed and thresholds are sanepass

Why It Matters

Circuit breakers protect external dependencies from retry storms. Bad thresholds either trip too aggressively or never trip when a downstream service is failing. Live breaker state shows whether the dependency is degraded right now.

Common Causes

How to Fix

Docker Compose

services:
  doctor-web:
    environment:
      Resilience__Enabled: "true"
      Resilience__CircuitBreaker__BreakDurationSeconds: "30"
      Resilience__CircuitBreaker__FailureThreshold: "5"
      Resilience__CircuitBreaker__SamplingDurationSeconds: "60"

If the check skips with ICircuitBreakerStateProvider not registered, wire the local resilience-state exporter into the Doctor host. Do not reset breakers from the check.

Bare Metal / systemd

Keep breaker settings in the same configuration source used for HTTP client registration so the service and Doctor observe the same values. Register the read-only resilience-state provider with the Doctor host process.

Kubernetes / Helm

Standardize resilience values across backend-facing workloads instead of per-pod overrides. Expose only read-only breaker state to Doctor; do not grant Doctor a breaker-reset capability.

Verification

stella doctor run --check check.servicegraph.circuitbreaker