Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

retry more #1419

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ public SystemSemaphoreManager()
.AddRetry(new RetryStrategyOptions()
{
ShouldHandle = new PredicateBuilder().Handle<Exception>(),
MaxRetryAttempts = 5, //means we'll wait for a max of around 250ms
MaxRetryAttempts = 20, //means we'll wait for a max of around 250ms
BackoffType = DelayBackoffType.Linear,
UseJitter = true,
Delay = TimeSpan.FromMilliseconds(50),
OnRetry = args =>
{
log.Verbose($"Waiting {args.RetryDelay.TotalMilliseconds}ms before attempting to acquire the Semaphore again");
log.Warn($"Waiting {args.RetryDelay.TotalMilliseconds}ms before attempting to acquire the Semaphore again");
return default;
}
})
Expand Down