Beispiel #1
0
 public CircuitBreaker(ICircuitBreakerStrategy strategy, CircuitBreakerOptions options = null)
 {
     Options            = options ?? new CircuitBreakerOptions();
     State              = Options.InitialState;
     StateLastChangedAt = DateTimeOffset.UtcNow;
     Strategy           = strategy;
 }
Beispiel #2
0
 public CircuitBreaker(ICircuitBreakerStrategy strategy, string name)
 {
     this.strategy = strategy;
     Name          = name;
 }