Add Parallel Multipart Download support for Pre-signed URL GetObject#6937
Open
jencymaryjoseph wants to merge 2 commits intofeature/master/pre-signed-url-getobjectfrom
Open
Add Parallel Multipart Download support for Pre-signed URL GetObject#6937jencymaryjoseph wants to merge 2 commits intofeature/master/pre-signed-url-getobjectfrom
jencymaryjoseph wants to merge 2 commits intofeature/master/pre-signed-url-getobjectfrom
Conversation
7f0be01 to
b19ed2e
Compare
ac6b49f to
78e9cba
Compare
b19ed2e to
c928799
Compare
…eptorSpec null check
joviegas
previously approved these changes
May 5, 2026
sorry was approving other PR accidentally clicked on this one
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation and Context
Adding support for
FileAsyncResponseTransformerPublisher(toFile path) in pre-signed URL multipart downloads.This introduces a parallel subscriber
ParallelPresignedUrlMultipartDownloaderSubscriberthat handles concurrent range requests and explicit resultFuture completion, similar toParallelMultipartDownloaderSubscriberfor regular multipart downloads.Also fixes error propagation in the serial subscriber (toBytes path) where resultFuture
was being completed after subscription cancel, allowing
ByteArraySplittingTransformertorace and assemble invalid data.
Also fixes small object downloads in the serial subscriber (toBytes path) by reordering
Content-Range parsing before validation, so S3's actual object range is correctly validated
instead of being compared against the larger requested range.
Modifications
ParallelPresignedUrlMultipartDownloaderSubscriber(NEW): Parallel subscriber for toFile().Discovers object size from first part, fires remaining parts concurrently (up to
maxInFlightParts=10). Completes resultFuture explicitly when all parts finish. Handles
single-part objects by completing immediately after first response.
PresignedUrlDownloadHelper: Routes based on split.parallelSplitSupported() — parallelsubscriber for toFile, serial subscriber for toBytes.
PresignedUrlMultipartDownloaderSubscriber: Added resultFuture field.Reordered validatePart to parse Content-Range before validation, fixing small object downloads where S3 returns the actual object range instead of the requested range.
handleError() completes resultFuture before cancel to prevent data corruption in toBytes() path.
Testing
PresignedUrlMultipartDownloaderSubscriberWiremockTest: Parameterized for toBytes/toFile,added small object test case
ParallelPresignedUrlMultipartDownloaderSubscriberTest(NEW): Single-part detection,multi-part download, error propagation, Content-Range validation failures
ParallelPresignedUrlMultipartDownloaderSubscriberTckTest(NEW): Reactive Streams TCKcompliance
PresignedUrlMultipartDownloaderSubscriberTckTest: Updated constructorScreenshots (if appropriate)
Types of changes
Checklist
mvn installsucceedsscripts/new-changescript and following the instructions. Commit the new file created by the script in.changes/next-releasewith your changes.License