Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GH-44334: [C++] Fix S3 error handling in ObjectOutputStream #44335

Merged
merged 1 commit into from
Oct 8, 2024

Conversation

OliLay
Copy link
Contributor

@OliLay OliLay commented Oct 8, 2024

Rationale for this change

See #GH-44334. Errors from the AWS SDK are not correctly propagated onto the user of the ObjectOutputStream, not indicating an error even though there was one in some cases.

What changes are included in this PR?

  • Directly pass the outcome of the AWS SDK to HandleUploadUsingSingleRequestOutcome aswell as HandleUploadPartOutcome instead of wrapping it in a arrow Result class which has been constructed implictily, always indicating success.
  • Adjust cleanup handling in Close so that the output stream is closed if there was an error in any of the called methods. Otherwise, destructing the output stream in debug builds fails as we abort if Close() returns something else than Status::OK(). See the code pointer here.

Are these changes tested?

  • Added assertions for catching exceptions on Close() in case delayed_open is enabled.

Are there any user-facing changes?

No.

Copy link

github-actions bot commented Oct 8, 2024

⚠️ GitHub issue #44334 has been automatically assigned in GitHub to PR creator.

@OliLay
Copy link
Contributor Author

OliLay commented Oct 8, 2024

FYI @pitrou This is related to #41564

Copy link
Member

@pitrou pitrou left a comment

Choose a reason for hiding this comment

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

Nice catch, thank you @OliLay !

@github-actions github-actions bot added awaiting committer review Awaiting committer review and removed awaiting review Awaiting review labels Oct 8, 2024
@pitrou pitrou merged commit c50c4fa into apache:main Oct 8, 2024
38 of 41 checks passed
@pitrou pitrou removed the awaiting committer review Awaiting committer review label Oct 8, 2024
Copy link

After merging your PR, Conbench analyzed the 4 benchmarking runs that have been run so far on merge-commit c50c4fa.

There were no benchmark performance regressions. 🎉

The full Conbench report has more details. It also includes information about 4 possible false positives for unstable benchmarks that are known to sometimes produce them.

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.

2 participants