Class CircuitBreakerConfiguration
Inheritance
System.Object
CircuitBreakerConfiguration
Namespace: Couchbase.Core.CircuitBreakers
Assembly: Couchbase.NetClient.dll
Syntax
public class CircuitBreakerConfiguration : object
Fields
| Improve this Doc View SourceDefault
Declaration
public static CircuitBreakerConfiguration Default
Field Value
Type | Description |
---|---|
CircuitBreakerConfiguration |
Properties
| Improve this Doc View SourceCanaryTimeout
The timeout for the canary request until it is deemed failed
Declaration
public TimeSpan CanaryTimeout { get; set; }
Property Value
Type | Description |
---|---|
TimeSpan |
CompletionCallback
Called on every response to determine if it is successful or not. The default implementation counts SocketException, TimeoutException and TaskCanceledExceptions, RequestCanceledException as failures.
Declaration
public Func<Exception, bool> CompletionCallback { get; set; }
Property Value
Type | Description |
---|---|
Func<Exception, System.Boolean> |
Enabled
Declaration
public bool Enabled { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
ErrorThresholdPercentage
The percentage of operations that need to fail in a window until the circuit opens.
Declaration
public uint ErrorThresholdPercentage { get; set; }
Property Value
Type | Description |
---|---|
System.UInt32 |
RollingWindow
The rolling time-frame which is used to calculate the error threshold percentage.
Declaration
public TimeSpan RollingWindow { get; set; }
Property Value
Type | Description |
---|---|
TimeSpan |
SleepWindow
The initial sleep time after which a canary is sent as a probe.
Declaration
public TimeSpan SleepWindow { get; set; }
Property Value
Type | Description |
---|---|
TimeSpan |
VolumeThreshold
The minimum amount of operations to measure before the threshold percentage kicks in.
Declaration
public int VolumeThreshold { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |