fix(firestore): retry transient connection errors in streaming RPCs#14620
fix(firestore): retry transient connection errors in streaming RPCs#14620bhshkh wants to merge 2 commits into
Conversation
|
Currently, unary RPCs automatically retry on This PR implements retry and resumption logic for the following streaming RPCs:
Other changes:
Retries are skipped if executing within a transaction ( |
There was a problem hiding this comment.
Code Review
This pull request implements retry logic for several Firestore operations, including BatchGetDocuments, RunQuery, and RunAggregationQuery. It introduces a centralized isRetryable helper function to identify transient errors—such as specific gRPC status codes and connection resets—and utilizes exponential backoff for retries. The queryDocumentIterator was updated to resume streaming from the last received document upon retry. Corresponding unit tests were added to verify the retry behavior across these methods. I have no feedback to provide.
Retry transient connection errors (specifically
syscall.ECONNRESETandsyscall.ECONNREFUSED) in Firestore streaming RPCs.Fixes: #10350