class CircuitState

Defined in:

circuit_state.cr

Constant Summary

ALLOWED_TRANSITIONS = {CLOSED => [OPEN], OPEN => [HALF_OPEN], HALF_OPEN => [OPEN, CLOSED]}
CLOSED = :closed
HALF_OPEN = :half_open
OPEN = :open

Constructors

Instance Method Summary

Constructor Detail

def self.new #

[View source]

Instance Method Detail

def attempt_reset #

[View source]
def reset #

[View source]
def state : Symbol #

[View source]
def trip #

[View source]