Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,11 @@ public Builder maxAttempts(Integer maxAttempts) {
* timeout doesn't have strict guarantees on how quickly a request is aborted when the timeout is breached. The request
* can timeout early if it is determined that the next retry will breach the max wait time. It's disabled by default.
*
* <p>When set, {@code waitTimeout} works alongside {@link #maxAttempts(Integer)}, which caps the number of polling

@joviegas joviegas Aug 19, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nits :

  1. Can we frame waitTimeout as an upper bound rather than a target, and if possible add the concrete Unexpected behavior from waiter if timeout provided #5838 case so it is clear the waiter errors out at the attempt limit, not after the full timeout?

  2. Can we add the note on maxAttempts too so both setters describe the interaction saying maxAttempts works with waitTimeout and waiters transitions to a failure state as soon as it reaches either limit.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Sure, the upper-bound framing with an example helps, revised.

  2. Thought about it initially, and scoped to waitTimeout since it's null by default. The interaction only kicks in when a customer explicitly sets it, and the misinterpretation was directional. But only fair to make it symmetric, added it.

* attempts and has a service-provided default. The waiter transitions to a failure state as soon as either limit
* is reached. To wait longer than the service-provided default, override {@link #maxAttempts(Integer)} to increase
* the number of polling attempts or {@link #backoffStrategyV2(BackoffStrategy)} to lengthen the delay between polls.
*
* @param waitTimeout The new waitTimeout value.
* @return This object for method chaining.
*/
Expand Down
Loading