maxAttempts

@Nullable
open fun maxAttempts(): @Nullable Integer

Maximum number of attempts before giving up retrying.

The initial call counts as the first attempt; retries increment the count by 1. When giving up, the behavior defined with onMaxAttempts will be applied.

See also


open fun maxAttempts(@Nullable maxAttempts: @Nullable Integer): InvocationRetryPolicy.Builder

Sets the maximum number of attempts before giving up retrying.

The initial call counts as the first attempt; retries increment the count by 1.