commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From C Rose <>
Subject Re: [FileUpload] Large file uploads are slow
Date Sun, 12 Mar 2006 14:27:23 GMT
Hi Martin, Sandy

Many thanks for your replies.

Sandy: Thanks for doing the profiling. Out of interest, what was the  
spec of the machine you did the profiling on?

I can live with the performance I'm getting and I'm glad to learn  
that the performance isn't down to a mistake on my part. I guess HTTP  
was never meant for transferring large files anyway.

Best regards


On 10 Mar 2006, at 19:09, C Rose wrote:

> Hi all
> I'm using commons-fileupload-1.1.jar to handle file uploads to a  
> servlet. I expect typical file uploads to be around 40MB is size.  
> However, the time taken to upload such files seems quite long.
> I have performed some profiling and have found that the call to  
> ServletFileUpload.parseRequest() takes about 20 seconds for a 45MB  
> file and accounts for over 80% of the time taken to upload the  
> file. This is measured on a 600MHz P3 machine (yeah, I know...)  
> with 512MB RAM running Linux, Sun's JVM and Tomcat. The machine is  
> acting as both the client and the server and is under little  
> additional load.
> I am using a DiskFileItemFactory, and the only thing I do to it is  
> mandate that the ServletFileUpload object created by the factory  
> does not have a limit on the size of the file being uploaded. The  
> transfer is going via HTTPS.
> Does this upload time seem reasonable?
> Is there anything I can do to speed things up?
> If parsing the request has to take so long, is it possible to  
> perform this task after having returned a response to the client  
> (e.g. start a new thread in which to call parseRequest() so that it  
> appears as though I've serviced the request fully)---or am I right  
> in thinking that an HttpServletRequest object will be 'invalid'  
> after an HttpServletResponse is sent to the client?
> Thanks in advance
> C
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message