-
Notifications
You must be signed in to change notification settings - Fork 910
Enable zero-copy ByteBuffer publishing in AsyncRequestBody "unsafe" constructors #4096
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
Merged
millems
merged 1 commit into
aws:master
from
StephenFlavin:enable-zero-copy-bytebuffers-in-asyncrequestbody-unsafe-methods
Jul 10, 2023
Merged
Enable zero-copy ByteBuffer publishing in AsyncRequestBody "unsafe" constructors #4096
millems
merged 1 commit into
aws:master
from
StephenFlavin:enable-zero-copy-bytebuffers-in-asyncrequestbody-unsafe-methods
Jul 10, 2023
Conversation
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
millems
approved these changes
Jun 27, 2023
Sorry about the delay on reviewing this. Looks great! Kicking off the tests... |
No worries @millems, wish I could see that test output 😅 |
12 tasks
hey @millems, |
It's something silly:
|
baa0b8c
to
0ba3e4f
Compare
🤦 fixed |
Rerunning tests |
Kudos, SonarCloud Quality Gate passed! |
Thanks for your contribution! Sorry about the long time getting it merged. |
L-Applin
pushed a commit
that referenced
this pull request
Jul 24, 2023
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.
Removes guards put in place on #3925 to ensure off-heap buffers were copied to on-heap.
This change to the code enables off-heap buffers to be published directly allowing improved performance zero-copy transfers.
Motivation and Context
see: #3928
This change is effectively running in my own production code where I upload files via MappedByteBuffer, when performance testing I was able to achieve a 25% performance improvement over
TransferManager
uploading a 1GB file.Modifications
Removes a condition in
ByteBuffersAsyncRequestBody
that converts a direct (off-heap) buffer to a non-direct (on-heap) buffer.Testing
The functionality is covered by existing tests, I've only removed a test which I put in place as a pre-cursor to this change
Screenshots (if appropriate)
Types of changes
Checklist
mvn install
succeedsscripts/new-change
script and following the instructions. Commit the new file created by the script in.changes/next-release
with your changes.License