Skip to content

Retry on Unavailable gRPC errors, reduce result channel buffer - #56

Merged
janezpodhostnik merged 1 commit into
mainfrom
janez/retry-unavailable-backpressure
Aug 10, 2026
Merged

Retry on Unavailable gRPC errors, reduce result channel buffer#56
janezpodhostnik merged 1 commit into
mainfrom
janez/retry-unavailable-backpressure

Conversation

@janezpodhostnik

@janezpodhostnik janezpodhostnik commented Aug 10, 2026

Copy link
Copy Markdown
Collaborator

Description

Add codes.Unavailable to the retryable gRPC status codes in the unary client
interceptor. Connection drops surface as Unavailable and are transient: gRPC
reconnects on the next attempt.

Reduce the ScriptResultProcessor results channel buffer from 10000 to 500 so
producers get backpressure earlier and memory usage stays bounded.

Most critical file to review: client/interceptors/uci_retry.go.


For contributor use:

  • Targeted PR against main branch
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Code follows the standards mentioned here.
  • Updated relevant documentation
  • Re-reviewed Files changed in the Github PR explorer
  • Added appropriate labels

Retry when the connection drops (codes.Unavailable); gRPC reconnects
on the next attempt so these errors are transient.

Reduce the script result channel buffer from 10000 to 500 to apply
backpressure to producers earlier and bound memory usage.
@janezpodhostnik janezpodhostnik self-assigned this Aug 10, 2026
@janezpodhostnik
janezpodhostnik merged commit b020e5f into main Aug 10, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant