Exemplo n.º 1
0
 public CircuitBreakerFactory(IHealthCountService service)
 {
     _service = service;
 }
Exemplo n.º 2
0
 /// <summary>
 /// Initializes an instance of CircuitBreaker
 /// </summary>
 /// <param name="key">The Key that defines a unique unit to be controlled by circuit breaker. E.g. a URI.</param>
 /// <param name="rules">Rules to be evaluated to decide if the state should be set to OPEN</param>
 /// <param name="service">service that deal with the persistance of the information</param>
 internal CircuitBreaker(string key, List <IRule> rules, IHealthCountService service)
 {
     _rules = rules;
     _keys  = new CircuitBreakerKeys(key);
     _healthCountService = service;
 }