Skip to content

feat(circuit-breaker): add per-scope circuit breaker with getCircuitState (#630) - #680

Open
ZacLou wants to merge 3 commits into
conduit-protocol:mainfrom
ZacLou:feat/630-expose-circuit-state
Open

feat(circuit-breaker): add per-scope circuit breaker with getCircuitState (#630)#680
ZacLou wants to merge 3 commits into
conduit-protocol:mainfrom
ZacLou:feat/630-expose-circuit-state

Conversation

@ZacLou

@ZacLou ZacLou commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Closes #630.

ZacLou and others added 2 commits September 5, 2026 22:47
…ol#630)

Adds a circuit breaker that tracks consecutive failures per RPC URL.
Consumers can call getCircuitState(rpcUrl) to check if the endpoint is
'closed' (healthy), 'open' (degraded), or 'half-open' (probing) without
catching thrown errors.

- src/rpc-circuit-state.ts: getCircuitState, recordSuccess, recordFailure,
  resetCircuit, getAllCircuitStates
- createRpcServer proxy now records success/failure on each RPC call
- Exported from the package entry point

Addresses conduit-protocol#630
@ZacLou
ZacLou force-pushed the feat/630-expose-circuit-state branch from 36394a6 to 760cc39 Compare September 5, 2026 23:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

createRpcServer: expose per-endpoint circuit state

2 participants