Re: How to Access File Streams Later

2016-05-30 Thread Thusitha Thilina Dayaratne
Hi Li Ying, Thanks for the detailed explanation. I will look into that. Btw I directly pass the FileItemIterator to service (without processing) so the developer can consume the streams at the service level. Do you find any issues with that approach? Best Regards Thusitha 2016-05-31 7:34 GMT+05:

Re: How to Access File Streams Later

2016-05-30 Thread Li Ying
Hi, Thusitha I beleive you have to use temporary files, for the following reasons: (1)If I remember correct, HTTP Request is an one-time input stream. That means, you have to read out (and consume) the whole HTTP Request content to retrieve the uploaded files and the other request parameters, so,

Re: How to Access File Streams Later

2016-05-30 Thread Thusitha Thilina Dayaratne
Hi Li Ying, Thanks for the response. Yeah I agree with you I can save a temp file and then create new set of stream. But when it comes to large files it will take much time since first I've to save the file and then send it to the actual service. Therefore I was thinking of not to process the stre

Re: How to Access File Streams Later

2016-05-30 Thread Li Ying
Hi Thusitha Maybe you need save the upload-file stream into a temporary file on your server. And then, you can access the file content from the temporary file 2016-05-30 14:43 GMT+09:00 Thusitha Thilina Dayaratne < thusithathil...@gmail.com>: > Hi All, > > I'm trying to use apache commons-fileup