Skip to content

estuary-cdk: retry connection timeouts#3065

Merged
Alex-Bair merged 1 commit intomainfrom
bair/estuary-cdk-retry-connection-timeouts
Jul 17, 2025
Merged

estuary-cdk: retry connection timeouts#3065
Alex-Bair merged 1 commit intomainfrom
bair/estuary-cdk-retry-connection-timeouts

Conversation

@Alex-Bair
Copy link
Copy Markdown
Member

@Alex-Bair Alex-Bair commented Jul 16, 2025

Description:

It's a good idea to retry connection timeouts a few times in case of intermittent errors from flaky APIs. This is safe to do in the request() method since it consumes the entire response body before returning, unlike request_lines() and request_stream() which yield chunks that may have already been processed before a timeout occurs.

Workflow steps:

(How does one use this feature, and how has it changed)

Documentation links affected:

(list any documentation links that you created, or existing ones that you've identified as needing updates, along with a brief description)

Notes for reviewers:

Tested the behavior with a small script. Confirmed a request is retried if a ConnectionTimeoutError is raised, and the error bubbles up once the request is attempted more than max_attempts times.


This change is Reviewable

It's a good idea to retry connection timeouts a few times in case of
intermittent errors from flaky APIs. This is safe to do in the request()
method since it consumes the entire response body before returning,
unlike request_lines() and request_stream() which yield chunks that may
have already been processed before a timeout occurs.
@Alex-Bair Alex-Bair marked this pull request as ready for review July 16, 2025 22:50
@Alex-Bair Alex-Bair requested a review from williamhbaker July 16, 2025 22:50
Copy link
Copy Markdown
Member

@williamhbaker williamhbaker left a comment

Choose a reason for hiding this comment

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

LGTM

@Alex-Bair Alex-Bair merged commit e7c8c7d into main Jul 17, 2025
129 of 143 checks passed
@Alex-Bair Alex-Bair deleted the bair/estuary-cdk-retry-connection-timeouts branch July 17, 2025 14:49
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.

2 participants