Skip to content

fix(bigtable): add exponential backoff on client transport failure retries - #14688

Closed
mutianf wants to merge 1 commit into
mainfrom
retry-transport-backoff
Closed

mutianf wants to merge 1 commit into
mainfrom
retry-transport-backoff

Conversation

@mutianf

@mutianf mutianf commented Oct 19, 2026

Copy link
Copy Markdown
Contributor

Stack created with GitHub Stacks CLI • Give Feedback 💬

@gemini-code-assist gemini-code-assist Bot left a comment

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.

Code Review

This pull request implements exponential backoff for retrying transport failures in RetryingVRpc and adds corresponding unit tests. The feedback highlights a potential NullPointerException if the operation deadline is null when calculating remaining time, suggesting a defensive check to default hasRemainingTime to true.

Comment on lines +303 to +306
boolean hasRemainingTime =
context.getOperationInfo().getDeadline().timeRemaining(TimeUnit.MILLISECONDS)
- retryDelayMs
> 1;

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.

medium

If the operation does not have a deadline configured, context.getOperationInfo().getDeadline() may return null. Calling timeRemaining on a null deadline will throw a NullPointerException. We should defensively check if the deadline is null and default hasRemainingTime to true in that case.

Suggested change
boolean hasRemainingTime =
context.getOperationInfo().getDeadline().timeRemaining(TimeUnit.MILLISECONDS)
- retryDelayMs
> 1;
io.grpc.Deadline deadline = context.getOperationInfo().getDeadline();
boolean hasRemainingTime =
deadline == null
|| deadline.timeRemaining(TimeUnit.MILLISECONDS) - retryDelayMs > 1;

@mutianf mutianf closed this Oct 19, 2026
@mutianf
mutianf deleted the retry-transport-backoff branch October 19, 2026 18:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant