Esempio n. 1
0
 /// <summary>
 /// Constructs a <see cref="CircuitBreakerStrategy"/> implementation.
 /// </summary>
 /// <param name="configuration">The circuit breaker configuration.</param>
 protected CircuitBreakerStrategy(CircuitBreakerConfigurationBase configuration)
 {
     this.stateHandler  = configuration.StateHandler;
     this.configuration = configuration;
 }
Esempio n. 2
0
 public DefaultCircuitBreakerStrategy(CircuitBreakerConfigurationBase configBase,
                                      DefaultCircuitBreakerStrategyConfiguration config) : base(configBase)
 {
     this.maxFailureCountBeforeOpen  = config.MaxFailureCountBeforeOpen;
     this.minSuccessCountBeforeClose = config.MinSuccessCountBeforeClose;
 }