<PackageReference Include="Polly.Core" Version="8.3.0" />

CircuitBreakerManualControl

public sealed class CircuitBreakerManualControl
Allows manual control of the circuit-breaker.

Initializes a new instance of the CircuitBreakerManualControl class.

public CircuitBreakerManualControl(bool isIsolated)

Initializes a new instance of the CircuitBreakerManualControl class.

public Task CloseAsync(CancellationToken cancellationToken = default)

Closes the circuit, and resets any statistics controlling automated circuit-breaking.

public Task IsolateAsync(CancellationToken cancellationToken = default)

Isolates (opens) the circuit manually, and holds it in this state until a call to CloseAsync is made.