Skip to content

Java v2: Update S3 examples of uploading from a stream of unknown size to remove use of BlockingInputStreamAsyncRequestBody#7513

Merged
rlhagerm merged 3 commits into
awsdocs:mainfrom
tkhill-AWS:s3_stream
Jul 8, 2025
Merged

Java v2: Update S3 examples of uploading from a stream of unknown size to remove use of BlockingInputStreamAsyncRequestBody#7513
rlhagerm merged 3 commits into
awsdocs:mainfrom
tkhill-AWS:s3_stream

Conversation

@tkhill-AWS

Copy link
Copy Markdown
Collaborator

This pull request updates two S3 code examples that show the use of BlockingInputStreamAsyncRequestBody when uploading content from a stream of unknown size. It turns out that this approach is 'dangerous' according to the Java SDK team and an update was recommended.

This PR also adds an one more example that uses same upload approach using the standard S3 async client with multipart enabled that users can alternatively use to upload.

There are now 3 examples using different clients.

CDD build is here.

Addresses this ticket.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@github-actions github-actions Bot added the Java-v2 This issue relates to the AWS SDK for Java V2 label Jul 3, 2025
@scmacdon scmacdon added the Single action example A new (or significant update to a) small example, label Jul 4, 2025
@scmacdon scmacdon self-requested a review July 4, 2025 14:37
scmacdon

This comment was marked as duplicate.

@scmacdon

scmacdon commented Jul 4, 2025

Copy link
Copy Markdown
Contributor

Show me a Cloud Desktop

@tkhill-AWS

Copy link
Copy Markdown
Collaborator Author

The link to the CDD is in the main description.

@scmacdon scmacdon added the On Call Review needed This work needs an on-call review label Jul 7, 2025
@rlhagerm rlhagerm added On Call Review complete On call review complete and removed On Call Review needed This work needs an on-call review labels Jul 8, 2025
@rlhagerm rlhagerm merged commit b791808 into awsdocs:main Jul 8, 2025
19 of 20 checks passed
@tkhill-AWS tkhill-AWS deleted the s3_stream branch July 14, 2025 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Java-v2 This issue relates to the AWS SDK for Java V2 On Call Review complete On call review complete Single action example A new (or significant update to a) small example,

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants