Comments (4)
Interesting, I'll take a look to see what is going on. Are you noticing performance regression from V1 of the SDK or from the previous version of the V2 SDK? How much regression are you seeing?
from aws-sdk-net.
The performance regression is from V1.
I'm getting perhaps 500kB/s upstream on an 18Mbps connection. Cyberduck (third party S3 client) easily gets 1.1MB/s upstream to the same bucket, and with V1 I was always able to match or beat Cyberduck.
from aws-sdk-net.
This diff (which hard-codes a buffer size of 64K instead of 4K) fixes my performance regression, bringing upload speeds back up to ~1.7MB/s:
--- a/AWSSDK_DotNet45/Amazon.Runtime/AmazonWebServiceClient.cs
+++ b/AWSSDK_DotNet45/Amazon.Runtime/AmazonWebServiceClient.cs
@@ -219,7 +219,7 @@ namespace Amazon.Runtime
var eventStream = new EventStream(request.ContentStream, true);
var tracker = new StreamReadTracker(this, request.OriginalRequest.StreamUploadProgressCallback, request.ContentStream.Length);
eventStream.OnRead += tracker.ReadProgress;
- requestMessage.Content = new StreamContent(eventStream);
+ requestMessage.Content = new StreamContent(eventStream, 64*1024);
requestMessage.Content.Headers.ContentLength = request.ContentStream.Length;
}
else if ((requestData = GetRequestData(request)) != null)
I couldn't see anywhere obvious in this method where I could get hold of the buffer size from AmazonS3Config, so I guess it would have to be attached to the IRequest or something like that.
from aws-sdk-net.
Closing as the BufferSize property is now being used by the .NET 4.5 runtime when reading from the stream.
from aws-sdk-net.
Related Issues (20)
- [v4] `CryptoUtil` refactoring opportunities. HOT 3
- SSO fails with "Failed to find sso_session" HOT 5
- SQS poll exception: System.InvalidOperationException: Collection was modified HOT 10
- AWSSDK.DynamoDB uses 'System.Net.Http.HttpClientHandler.Send' method which produces a 'System.PlatformNotSupportedException' in MAUI apps targeting Android/iOS - Use method 'SendAsync' instead, which is supported. HOT 5
- S3Control CreateJobAsync with LambdaInvoke throws 'Request invalid' exception due to empty UserArguments HOT 2
- IoT Core MQTT with SQS and .NET Framework 4.8 intermittently drops payload attribute HOT 4
- Return MemoryStreams with accessible buffers HOT 7
- Do not create strings just for comparison HOT 4
- Avoid StringBuilder.AppendFormat HOT 5
- Avoid creating unnecessary intermediate strings HOT 5
- Migrating from .Net 6 to .Net 8 HOT 4
- Using the SDK in web application testing broken (.NET 8 URI canonicalization) HOT 6
- Using SSO in .NET Core with Docker Compose HOT 7
- Amazon.S3.Transfer TransferUtility.UploadAsync() throwing exception under .Net 8 with latest MS and AWS SDK NuGet packages HOT 6
- Critical DateTime to Epoch serialization issue for DynamoDb when date is beyond epoch supported date HOT 2
- Missing Models for SES HOT 5
- Switch .net 472 version of SDK to use HttpClient instead of HttpWebRequest HOT 4
- Support conditional put in TransferUtility (S3) HOT 2
- Add option to AWSConfigs to only use ec2 instance profile role for AWSCredentials HOT 2
- Clock skew correction causes repeated retries HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aws-sdk-net.