commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Courcoux <>
Subject [FileUpload] Support for Progress Reporting
Date Thu, 24 Apr 2003 15:29:26 GMT

I have implemented upload progress reporting for my turbine 2.2
application. I am about to switch to turbine 2.3 which uses
commons-fileupload in place of its own upload service.

Would you have any objections to providing support for this in
commons-fileupload. The changes needed would be 

to set a bytesRead property in MultipartStream on each read() from
stream to buffer operation, 

provide an accessor for bytesRead

to make the MultipartStream an instance property in FileUpload and to
provide a synchronized method to return its bytesRead value. Can anyone
see any threading issues with this?

provide a method to return the total request size from FileUpload

provide a method to return the name of the File being read by FileUpload

I believe that the changes would be backward compatible. There would be
a small performance impact on incrementing bytesRead but I would propose
that this is incremented only on a buffer read, as a compromise between 
granularity and performance.


I can provide patches in due course.



Peter Courcoux <>

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

View raw message