You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.MD
+4Lines changed: 4 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -173,6 +173,9 @@ This example demonstrates how to add custom headers to your email message.
173
173
### [Basic send with a web proxy](https://github.com/socketlabs/socketlabs-csharp/blob/master/Example%20Projects/dotNetCoreExample/Examples/Basic/BasicSendWithProxy.cs)
174
174
This example demonstrates how to use a proxy with your HTTP client.
175
175
176
+
### [Basic send with retry enabled](https://github.com/socketlabs/socketlabs-csharp/blob/master/Example%20Projects/dotNetCoreExample/Examples/Basic/BasicSendWithRetry.cs)
177
+
This example demonstrates how to use the retry logic with your HTTP client.
This example demonstrates many features of the Basic Send, including adding multiple recipients, adding message and mailing id's, and adding an embedded image.
178
181
@@ -205,6 +208,7 @@ For more information about AMP please see [AMP Project](https://amp.dev/document
205
208
206
209
<aname="version"></a>
207
210
# Version
211
+
* 1.2.2 - Adding optional retry logic for Http requests. If configured, the request will retry when certain 500 errors occur (500, 502, 503, 504)
208
212
* 1.2.1 - Adding request timeout value on the client for Http requests
209
213
* 1.2.0 - Can now pass in instance of HTTP client, adds .NET 5.0 support
<authors>Joe Cooper, David Schrenker, Matt Reibach, Ryan Lydzinski (Contributor), Mike Goodfellow (Contributor), Saranya Kavuri (Contributor)</authors>
if(maximumNumberOfRetries<0)thrownewArgumentOutOfRangeException(nameof(maximumNumberOfRetries),"maximumNumberOfRetries must be greater than 0");
26
+
if(maximumNumberOfRetries>5)thrownewArgumentOutOfRangeException(nameof(maximumNumberOfRetries),$"The maximum number of allowed retries is {_maximumAllowedNumberOfRetries}");
/// The maximum number of retries when sending an Injection API Request before throwing an exception. Default: 0, no retries, you must explicitly enable retry settings
0 commit comments