Package com.google.api.gax.retrying
Class TimedAttemptSettings
java.lang.Object
com.google.api.gax.retrying.TimedAttemptSettings
Timed attempt execution settings. Defines time-specific properties of a retry attempt.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract intThe attempt count.abstract longThe start time of the first attempt.abstract RetrySettingsReturns global (attempt-independent) retry settings.abstract intThe overall attempt count.abstract org.threeten.bp.DurationReturns randomized attempt delay.abstract org.threeten.bp.DurationReturns the calculated retry delay.abstract org.threeten.bp.DurationReturns rpc timeout used for this attempt.static TimedAttemptSettings.Builderabstract TimedAttemptSettings.Builder
-
Constructor Details
-
TimedAttemptSettings
public TimedAttemptSettings()
-
-
Method Details
-
getGlobalSettings
Returns global (attempt-independent) retry settings. -
getRetryDelay
public abstract org.threeten.bp.Duration getRetryDelay()Returns the calculated retry delay. Note that the actual delay used for retry scheduling may be different (randomized, based on this value). -
getRpcTimeout
public abstract org.threeten.bp.Duration getRpcTimeout()Returns rpc timeout used for this attempt. -
getRandomizedRetryDelay
public abstract org.threeten.bp.Duration getRandomizedRetryDelay()Returns randomized attempt delay. By default this value is calculated based on theretryDelayvalue, and is used as the actual attempt execution delay. -
getAttemptCount
public abstract int getAttemptCount()The attempt count. It is a zero-based value (first attempt will have this value set to 0). For streamed RPCs this will be reset after every successful message. -
getOverallAttemptCount
public abstract int getOverallAttemptCount()The overall attempt count. It is a zero-based value (first attempt will have this value set to 0). This will be the sum of all attempt counts for a streaming RPC and will be equal togetAttemptCount()for unary RPCs. -
getFirstAttemptStartTimeNanos
public abstract long getFirstAttemptStartTimeNanos()The start time of the first attempt. Note that this value is dependent on the actualApiClockused during the process. -
toBuilder
-
newBuilder
-