Example #1
0
 public async Task RetryAsync()
 {
     // Execute the DoWorkAsync
     await Retry.ExecuteAsync(async() =>
     {
         await DummyMethods.DoWorkAsync();
     }, TimeSpan.FromMilliseconds(100), 2);
 }
Example #2
0
 public async Task RetryAsyncWithAllFeatures()
 {
     // Execute the DoWorkAsync
     await Retry.ExecuteAsync(async() => await DummyMethods.DoWorkAsync(), TimeSpan.FromMilliseconds(100), 2, DummyMethods.ExecuteOnExceptionAsync, DummyMethods.ExecuteOnExceptionAsync, typeof(ArgumentException));
 }