fix(aws_S3 source): Add timeout for s3 operations. Add more error logging when get object fails. #25873
fix(aws_S3 source): Add timeout for s3 operations. Add more error logging when get object fails. #25873petere-datadog wants to merge 5 commits into
Conversation
The aws_s3 source created its S3 client with no read or operation timeout (only the SDK-default ~3.1s connect timeout). A half-open or silently dropped connection -- for example one reaped by a NAT gateway idle timeout -- could therefore hang a polling task indefinitely on the GetObject response-body read, stopping SQS polling entirely and stalling S3-based ingestion until the process was restarted. Retries are disabled on this client, so there was no recovery. Apply default S3 client timeouts (connect_timeout_seconds=5, read_timeout_seconds=30) and expose them as source configuration. The read timeout is applied per-read, so a slow but steadily progressing transfer of a large object is not cut off; no operation timeout is set by default to avoid capping legitimately long transfers. This mirrors the existing SQS client timeout support on the same source. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…ik/aws-read-timeout
Error logs for failed S3 events only included the SQS message ID, making it hard to tell which S3 object actually failed without cross-referencing. Log the object key (when known) alongside the error at error level.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 644e4cd109
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 273a0fd98a
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Summary
Change Type
Is this a breaking change?
Does this PR include user facing changes?
no-changeloglabel to this PR.References
Notes
@vectordotdev/vectorto reach out to us regarding this PR.pre-pushhook, please see this template.make fmtmake check-clippy(if there are failures it's possible some of them can be fixed withmake clippy-fix)make testgit merge origin masterandgit push.Cargo.lock), pleaserun
make build-licensesto regenerate the license inventory and commit the changes (if any). More details on the dd-rust-license-tool.