示例#1
0
            bool RetryContext <TContext> .CanRetry(Exception exception, out RetryContext <TContext> retryContext)
            {
                retryContext = new TestRetryContext <TContext>(_policy, Context, Exception, RetryCount + 1, CancellationToken);

                return(RetryAttempt < _policy.RetryLimit);
            }
示例#2
0
            public bool CanRetry(Exception exception, out RetryContext <TContext> retryContext)
            {
                retryContext = new TestRetryContext <TContext>(_policy, Context, exception, 0, CancellationToken);

                return(_policy.IsHandled(exception));
            }