Package com.google.cloud
Class RetryOption
java.lang.Object
com.google.cloud.RetryOption
- All Implemented Interfaces:
Serializable
This class represents an options wrapper around the
RetrySettings class and is an
alternative way of initializing it. The retry options are usually provided in a form of varargs
for methods that wait for changes in the status of a resource, do poll operations or retry on
failures.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbooleaninthashCode()static RetryOptioninitialRetryDelay(org.threeten.bp.Duration initialRetryDelay) static RetryOptionjittered(boolean jittered) SeeRetrySettings.isJittered()()}.static RetryOptionmaxAttempts(int maxAttempts) static RetryOptionmaxRetryDelay(org.threeten.bp.Duration maxRetryDelay) static RetrySettingsmergeToSettings(RetrySettings settings, RetryOption... options) Creates a newRetrySettingsinstance, merging provided settings and multipleRetryOptions, each of which represents a single property inRetrySettings.static RetryOptionretryDelayMultiplier(double retryDelayMultiplier) static RetryOptiontotalTimeout(org.threeten.bp.Duration totalTimeout)
-
Method Details
-
totalTimeout
-
initialRetryDelay
-
retryDelayMultiplier
-
maxRetryDelay
-
maxAttempts
-
jittered
SeeRetrySettings.isJittered()()}. -
equals
-
hashCode
public int hashCode() -
mergeToSettings
Creates a newRetrySettingsinstance, merging provided settings and multipleRetryOptions, each of which represents a single property inRetrySettings. It is an alternative way of initializingRetrySettingsinstances.- Parameters:
settings- retry settingsoptions- zero or more Retry- Returns:
- new
RetrySettingsinstance, which is a result of mergingoptionsintosettings, i.e. each element inoptions, if present, overrides corresponding property insettings
-