Created
February 25, 2017 22:58
-
-
Save ksysiekj/1ea0af5bc0bc013f17c71c68c4381cfb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RetryHandler.RetryFor<WebException>(() => | |
{ | |
string content = DownloadContent(); | |
Console.Write(content); | |
}, TimeSpan.FromSeconds(75), TimeSpan.FromSeconds(2), httpRequestException => httpRequestException.Status == WebExceptionStatus.Timeout | |
|| httpRequestException.Status == WebExceptionStatus.ConnectFailure, Logger); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment