ResilienceContext
A context assigned to a single execution of ResilienceStrategy. It is created manually or automatically
when the user calls the various extensions on top of ResilienceStrategy. After every execution the context should be discarded and returned to the pool.
Gets or sets the CancellationToken associated with the execution.
Gets or sets a value indicating whether the execution should continue on the captured context.
Gets a value indicating whether the execution is synchronous.
Gets a value indicating whether the execution represents a void result.
Gets a key unique to the call site of the current execution.
Gets the custom properties attached to the context.
Gets the collection of resilience events that occurred while executing the resilience strategy.
Gets the type of the result associated with the execution.
Gets a ResilienceContext instance from the pool.
public static ResilienceContext Get(string operationKey, CancellationToken cancellationToken = default)
Gets a ResilienceContext instance from the pool.
Returns a context back to the pool.