Class RetryConfigBuilder<T extends Response>
java.lang.Object
com.linecorp.armeria.client.retry.RetryConfigBuilder<T>
Builds a
RetryConfig.
A RetryConfig instance encapsulates the used RetryRule, maxTotalAttempts,
and responseTimeoutMillisForEachAttempt.-
Method Summary
Modifier and TypeMethodDescriptionbuild()Returns a newly-createdRetryConfigfrom thisRetryConfigBuilder's values.maxContentLength(int maxContentLength) Sets the specifiedmaxContentLengthto be used with aRetryRuleWithContent.maxTotalAttempts(int maxTotalAttempts) Sets the specifiedmaxTotalAttempts.responseTimeoutForEachAttempt(Duration responseTimeoutMillisForEachAttempt) Sets the specifiedDurationby converting responseTimeoutForEachAttempt to millis.responseTimeoutMillisForEachAttempt(long responseTimeoutMillisForEachAttempt) Sets the specifiedresponseTimeoutMillisForEachAttempt.toString()
-
Method Details
-
maxContentLength
Sets the specifiedmaxContentLengthto be used with aRetryRuleWithContent. -
maxTotalAttempts
Sets the specifiedmaxTotalAttempts. -
responseTimeoutMillisForEachAttempt
public RetryConfigBuilder<T> responseTimeoutMillisForEachAttempt(long responseTimeoutMillisForEachAttempt) Sets the specifiedresponseTimeoutMillisForEachAttempt. -
responseTimeoutForEachAttempt
public RetryConfigBuilder<T> responseTimeoutForEachAttempt(Duration responseTimeoutMillisForEachAttempt) Sets the specifiedDurationby converting responseTimeoutForEachAttempt to millis. -
build
Returns a newly-createdRetryConfigfrom thisRetryConfigBuilder's values. -
toString
-