Prevent OOME when uploading.  Set the file length in the metadata so it's not read into memory by s3 sdk.
Prevent OOME when uploading.
 Set the file length in the metadata so it's not read into memory by s3 sdk.

 As per the s3 sdk docs:

"Content length must be specified before data can be uploaded to Amazon S3. If the caller doesn't provide it, the library will have to buffer the contents of the input stream in order to calculate it because Amazon S3 explicitly requires that the content length be sent in the request headers before any of the data is sent."

http://docs.amazonwebservices.com/AWSJavaSDK/latest/javadoc/com/amazonaws/services/s3/AmazonS3Client.html#putObject(java.lang.String, java.lang.String, java.io.InputStream, com.amazonaws.services.s3.model.ObjectMetadata)

Jimilian/s3-plugin,Jimilian/s3-plugin