@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.
41 lines • 1.28 kB
JavaScript
/**
* @module CircuitBreaker
*/
import {} from "../../circuit-breaker/contracts/circuit-breaker-state.contract.js";
/**
* The constant represents all available state transition when in closed state
*
* IMPORT_PATH: `"@daiso-tech/core/circuit-breaker/contracts"`
* @group Contracts
*/
export const CLOSED_TRANSITIONS = {
/**
* This field indicates that circuit breaker will transition from closed to open state.
*/
TO_OPEN: "TO_OPEN",
/**
* This field indicates that circuite breaker will stay in closed state and not transition.
*/
NONE: "NONE",
};
/**
* The constant represents all available state transition when in half open state
*
* IMPORT_PATH: `"@daiso-tech/core/circuit-breaker/contracts"`
* @group Contracts
*/
export const HALF_OPEN_TRANSITIONS = {
/**
* This field indicates that circuit breaker will transition from half open to open state.
*/
TO_OPEN: "TO_OPEN",
/**
* This field indicates that circuit breaker will transition from half openb to closed state.
*/
TO_CLOSED: "TO_CLOSED",
/**
* This field indicates that circuite breaker will stay in half open state and not transition.
*/
NONE: "NONE",
};
//# sourceMappingURL=circuit-breaker-policy.contract.js.map