AWS SDK Version 2 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

.NET Framework 4.5
 
A retry policy specifies all aspects of retry behavior. This includes conditions when the request should be retried, checks of retry limit, preparing the request before retry and introducing delay (backoff) before retries.

Inheritance Hierarchy

System.Object
  Amazon.Runtime.RetryPolicy

Namespace: Amazon.Runtime
Assembly: AWSSDK.dll
Version: (assembly version)

Syntax

C#
public abstract class RetryPolicy : Object

The RetryPolicy type exposes the following members

Properties

NameTypeDescription
Public Property Logger Amazon.Runtime.Internal.Util.ILogger The logger used to log messages.
Public Property MaxRetries System.Int32 Maximum number of retries to be performed. This does not count the initial request.

Methods

NameDescription
Public Method CanRetry(IExecutionContext) Returns true if the request is in a state where it can be retried, else false.
Public Method Retry(IExecutionContext, Exception) Checks if a retry should be performed with the given execution context and exception.
Public Method RetryForException(IExecutionContext, Exception) Return true if the request should be retried for the given exception.
Public Method RetryLimitReached(IExecutionContext) Checks if the retry limit is reached.
Public Method WaitBeforeRetry(IExecutionContext) Waits before retrying a request.

Version Information

.NET Framework:
Supported in: 4.5, 4.0, 3.5

.NET for Windows Store apps:
Supported in: Windows 8.1, Windows 8

.NET for Windows Phone:
Supported in: Windows Phone 8.1, Windows Phone 8