Our solution
Contain subgraph failures without losing the whole API
The router tracks each subgraph on every request. When failures exceed your thresholds, it opens the circuit, rejects requests immediately, and probes recovery after the sleep window.
What happens when the circuit breaker trips
A request to a subgraph fails, and the error rate rises inside the rolling window.
When the configured threshold is exceeded and the minimum request count is met, the circuit opens.
Requests to that subgraph are rejected immediately instead of waiting for timeouts.
Healthy subgraphs continue resolving normally while the failed service is isolated.
After the sleep window, the circuit moves to half-open and allows limited test requests.
If enough test requests succeed, the circuit closes. If a test request fails, it opens again.
The failure stays contained while recovery happens through configurable half-open testing.

