-
Notifications
You must be signed in to change notification settings - Fork 863
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
S3 - OpenStreamAsync/GetObjectAsync randomly end with "The response ended prematurely with at least X bytes expected" #3674
Comments
In your reproduction code, you're setting the |
We are using a 3rd-party implementation provided by Nutanix called Nutanix objects |
Got it. FYI I did try your example against S3 (using a smaller object - around 70 MB), and it did not fail once for the 1000 iterations. We also made a change to the SDK last month (#3610) and some 3rd-party implementations were impacted, but all reports we received were related to uploading objects (not downloading them). |
Thanks for your time on my repro. |
The exceptions you're seeing make me believe it's an issue with the (3rd-party) server not being able to handle the load, however if you're able to reproduce it with S3 we can reach out to the service team for help. This won't solve the problem, but you can also enable debug logging by adding these lines prior to creating the S3 client (I haven't tested with that specific 3rd-party, but with S3 this will show the canonical request, request ID, and other useful troubleshooting information):
|
Seems a good one. |
Clearly, these lines have added a lot of information. We tried on a AWS S3 and, obviously, it worked like a charm. |
Yes, it looks like it may be a problem with the 3rd-party implementation so I'm afraid we won't be able to help here (and you'll need to work with them to figure out the root cause). |
Comments on closed issues are hard for our team to see. |
Describe the bug
When we upload big file ( > 200Mb in our usecase ) we, randomly, have an issue if we try to get the stream right after upload it on the S3 Storage
We're using the TransferUtility methods as follow :
Regression Issue
Expected Behavior
I want to be able to work with the stream of a blob i just uploaded without getting any exception.
Current Behavior
We encountered different exceptions according to the operations we're doing with the stream.
The first one is a simple CopyToAsync to a local MemoryStream
The second one is clearly the same but we're trying to broadcast the stream directly to an Azure Storage :
And if i'm not using a custom HTTPHandlerFactory
Reproduction Steps
My only usecase is in a loop for now, but it seems to encounter the issue pretty quickly on my side (less than 30 iterations, sometimes even the 2nd iteration is throwing) :
Possible Solution
No response
Additional Information/Context
Only having the issue with big files, the test provided was run with a 220Mb file. Having the issue with a 50Mb file too.
AWS .NET SDK and/or Package version used
AWSSDK.S3 v3.7.405.7
Targeted .NET Platform
.NET 8
Operating System and version
Windows 11
The text was updated successfully, but these errors were encountered: