Table of Contents

Class CircuitBreakerStateChangedEventArgs

Namespace
WorkflowForge.Extensions.Resilience.Abstractions
Assembly
WorkflowForge.Extensions.Resilience.dll

Event arguments for circuit breaker state changes.

public sealed class CircuitBreakerStateChangedEventArgs : EventArgs
Inheritance
CircuitBreakerStateChangedEventArgs
Inherited Members

Constructors

CircuitBreakerStateChangedEventArgs(CircuitBreakerState, CircuitBreakerState, string, ISystemTimeProvider?)

Initializes a new instance of the CircuitBreakerStateChangedEventArgs class.

public CircuitBreakerStateChangedEventArgs(CircuitBreakerState previousState, CircuitBreakerState currentState, string reason, ISystemTimeProvider? timeProvider = null)

Parameters

previousState CircuitBreakerState

The previous state.

currentState CircuitBreakerState

The current state.

reason string

The reason for the state change.

timeProvider ISystemTimeProvider

Optional time provider for timestamp.

Properties

CurrentState

Gets the current state.

public CircuitBreakerState CurrentState { get; }

Property Value

CircuitBreakerState

PreviousState

Gets the previous state.

public CircuitBreakerState PreviousState { get; }

Property Value

CircuitBreakerState

Reason

Gets the reason for the state change.

public string Reason { get; }

Property Value

string

Timestamp

Gets the timestamp of the state change.

public DateTimeOffset Timestamp { get; }

Property Value

DateTimeOffset