Table of Contents

Class ElasticsearchCircuitBreakerOptions

Namespace
Excalibur.Data.ElasticSearch
Assembly
Excalibur.Data.ElasticSearch.dll

Configures circuit breaker behavior for the Elasticsearch client, preventing cascading failures.

public sealed class ElasticsearchCircuitBreakerOptions
Inheritance
ElasticsearchCircuitBreakerOptions
Inherited Members

Remarks

Named for its provider rather than bare, because the framework also ships a circuit-breaker options type for the dispatch pipeline. A consumer configuring both would otherwise hold two types of one name in scope and have to disambiguate a collision the framework created.

Properties

BreakDuration

Gets the duration to keep the circuit open.

public TimeSpan BreakDuration { get; init; }

Property Value

TimeSpan

A TimeSpan representing the break duration. Defaults to 30 seconds.

Enabled

Gets a value indicating whether circuit breaker is enabled.

public bool Enabled { get; init; }

Property Value

bool

A bool indicating whether circuit breaker is active. Defaults to true .

FailureRatio

Gets the failure-to-success ratio, from 0.0 to 1.0, at which the circuit opens.

public double FailureRatio { get; init; }

Property Value

double

A double representing the failure ratio. Defaults to 0.5 (50%).

MinimumThroughput

Gets the minimum throughput before circuit breaker evaluation.

public int MinimumThroughput { get; init; }

Property Value

int

An int representing the minimum requests in the sampling duration. Defaults to 10.

SamplingDuration

Gets the sampling duration for failure rate calculation.

public TimeSpan SamplingDuration { get; init; }

Property Value

TimeSpan

A TimeSpan representing the sampling window. Defaults to 60 seconds.