UNPKG

@daiso-tech/core

Version:

The library offers flexible, framework-agnostic solutions for modern web applications, built on adaptable components that integrate seamlessly with popular frameworks like Next Js.

32 lines 1.02 kB
/** * @module CircuitBreaker */ /** * Enumerated states for circuit breaker operation. * - CLOSED: Circuit is operating normally, requests pass through * - OPEN: Circuit has detected failures, all requests are blocked * - HALF_OPEN: Testing if the service has recovered, limited requests allowed * - ISOLATED: Manually isolated, all requests are blocked until reset * * IMPORT_PATH: `"@daiso-tech/core/circuit-breaker/contracts"` * @group Contracts */ export const CIRCUIT_BREAKER_STATE = { /** * Open state. Requests are blocked while failures are being handled. */ OPEN: "OPEN", /** * Transitional state. Service is being tested to see if it has recovered. */ HALF_OPEN: "HALF_OPEN", /** * Closed state (normal operation). Requests are allowed. */ CLOSED: "CLOSED", /** * Manually isolated state. All requests are blocked regardless of service health. */ ISOLATED: "ISOLATED", }; //# sourceMappingURL=circuit-breaker-state.contract.js.map