camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Zoran Regvart <zo...@regvart.com>
Subject Re: S3 MultiPart upload for InputStream
Date Wed, 29 Mar 2017 16:56:34 GMT
Hi Artur,
I don't think that the implementation will load the whole file in
memory, looking at CAMEL-7991[1] that introduced multipart support the
reasoning behind it was to reduce the memory usage.
That being said if you have the need for passing InputStream instead,
could you consider contributing support for that, see Contributing at
https://camel.apache.org/contributing.html

thanks :)

zoran


[1] https://issues.apache.org/jira/browse/CAMEL-7991

On Wed, Mar 29, 2017 at 6:38 PM, Artur <ajablonski@ravenpack.com> wrote:
> Hello,
>
> i am trying to use the AWS-S3 component to multipart upload to S3.
>
> The content is coming via network and I was trying to pass an InputStream to
> the component for uploading.
>
> This fails with this message:
>
> aws-s3: MultiPart upload requires a File input. (Service: null; Status Code:
> 0; Error Code: null; Request ID: null)]
>
> I looked at the source code and it seems that when using the component
> indeed only File can be passed to it.
> The question is.. why.
>
> Imagine there's a very very very large file that your app can get over
> network and you want to upload it to s3. It makes sense to do mlutipart not
> to load the whole file in memory, so the component could read the bytes in
> chunks and pass it to s3 multipart api. You don't have an option of storing
> that file to disk first (which doesn't make sense in that case anyway).
>
> Is this scenario not supported for any particular reason?
>
> Thanks Artur
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/S3-MultiPart-upload-for-InputStream-tp5796702.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Zoran Regvart

Mime
View raw message