views:

117

answers:

2

I was wondering what Java File Upload API's StackOverflow users have used in the past and would recommend using? A quick Google Search seems to indicate that the most commonly used API is Apache Commons File Upload (currently at 1.2.1), however, we've had some issues regarding the use of this library with larger files that we've been unable to solve.

Has anyone found a reliable file upload library (aside from the Apache Commons one) that they'd recommend?

EDIT: The Steaming API is not an option as it uses the same underlying class that is causing our issue.

EDIT2: Our original issue appears to be some kind of problem with load balancing. Our clone instance uses Apache/AJP1.3 and the live instance uses Zeus XTM. Bypassing the load balancer by using the server IP rather than host name seems to cause the problem to disappear.

+1  A: 

If you have time or memory related problems, have you looked at the streaming API of commons file upload?

naikus
Yes. We've looked at the source and found that it uses the class we're having issues with - org.apache.commons.fileupload.MultipartStream.
Jon
A: 

have a look at theese settings, the limit is 8MB by default

upload_max_filesize
post_max_size
zolex
Where are these settings? In commons file upload itself? I had a quick Google and they appear to be Apache settings. We're not using Apache..
Jon
In the docs (http://commons.apache.org/fileupload/using.html) it says that you can set a Max upload size for an upload by doing `upload.setSizeMax(yourMaxRequestSize);` - but the default for this value is -1, which is no limit.
Jon