Class RetryPolicy.RetryPolicyBuilder
The builder class of RetryPolicy.
Inheritance
System.Object
RetryPolicy.RetryPolicyBuilder
Namespace: Amazon.QLDB.Driver
Assembly: Amazon.QLDB.Driver.dll
Syntax
public class RetryPolicyBuilder : object
Methods
| Improve this Doc View SourceBuild()
Build a RetryPolicy instance.
Declaration
public RetryPolicy Build()
Returns
Type | Description |
---|---|
RetryPolicy | A RetryPolicy instance. |
WithBackoffStrategy(IBackoffStrategy)
Sets the backoff strategy of the retry policy. If not called, the default ExponentBackoffStrategy would be used.
Declaration
public RetryPolicy.RetryPolicyBuilder WithBackoffStrategy(IBackoffStrategy backoffStrategy)
Parameters
Type | Name | Description |
---|---|---|
IBackoffStrategy | backoffStrategy | The backoff strategy. |
Returns
Type | Description |
---|---|
RetryPolicy.RetryPolicyBuilder | The builder instance. |
WithMaxRetries(Int32)
Sets the maximum number of retries. If not called, the default value is 4.
Declaration
public RetryPolicy.RetryPolicyBuilder WithMaxRetries(int maxRetries)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | maxRetries | The maximum number of retries. |
Returns
Type | Description |
---|---|
RetryPolicy.RetryPolicyBuilder | The builder instance. |