Class ExponentialRetryProperties
java.lang.Object
com.azure.spring.cloud.core.properties.retry.ExponentialRetryProperties
- All Implemented Interfaces:
RetryOptionsProvider.RetryOptions.ExponentialRetryOptions
public class ExponentialRetryProperties
extends Object
implements RetryOptionsProvider.RetryOptions.ExponentialRetryOptions
Properties of the exponential retry mode.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the delay duration.Get the max delay duration.The maximum number of attempts.void
setBaseDelay
(Duration baseDelay) Set the amount of time to wait between retry attempts.void
setMaxDelay
(Duration maxDelay) Set the maximum permissible amount of time between retry attempts.void
setMaxRetries
(Integer maxRetries) Set the maximum number of attempts.
-
Constructor Details
-
ExponentialRetryProperties
public ExponentialRetryProperties()
-
-
Method Details
-
getMaxRetries
Description copied from interface:RetryOptionsProvider.RetryOptions.ExponentialRetryOptions
The maximum number of attempts.- Specified by:
getMaxRetries
in interfaceRetryOptionsProvider.RetryOptions.ExponentialRetryOptions
- Returns:
- the max attempts.
-
setMaxRetries
Set the maximum number of attempts.- Parameters:
maxRetries
- the maximum number of attempts.
-
getBaseDelay
Description copied from interface:RetryOptionsProvider.RetryOptions.ExponentialRetryOptions
Get the delay duration.- Specified by:
getBaseDelay
in interfaceRetryOptionsProvider.RetryOptions.ExponentialRetryOptions
- Returns:
- the delay duration.
-
setBaseDelay
Set the amount of time to wait between retry attempts.- Parameters:
baseDelay
- The delay to wait between retry attempts.
-
getMaxDelay
Description copied from interface:RetryOptionsProvider.RetryOptions.ExponentialRetryOptions
Get the max delay duration.- Specified by:
getMaxDelay
in interfaceRetryOptionsProvider.RetryOptions.ExponentialRetryOptions
- Returns:
- the max delay duration.
-
setMaxDelay
Set the maximum permissible amount of time between retry attempts.- Parameters:
maxDelay
- The maximum permissible amount of time between retry attempts.
-