File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes Struts file upload size limit Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts file upload size limit" Watch "Struts file upload size limit" New topic
Author

Struts file upload size limit

Dave Knipp
Ranch Hand

Joined: Oct 14, 2003
Posts: 146
Hi,
I'm in the process of converting an existing jsp to use struts. The jsp has a multipart form that was previously parsed and handled by using the apache fileupload project. The upload should be able to handle large files, in excess of 1MB.
My question is, how does the struts framework utilize the fileupload project?? I know that all you have to do is use the html:file tag and then store it in your action form as type FormFile. But i was curious if anyone knows if the struts framework uses temp files to store the file data if it is too large to hold in memory. I previously ran into out of memory errors and solved it by using the fileupload projects temp file storing capabilities. Does struts use that same methodology? If not does anyone know of a proper solution?
Thanks,
Dave


SCJP 1.4, SCJD 1.4, SCWCD 1.3, SCBCD 1.3, IBM Certified Solution Developer -WebSphere Studio V5.0
Shrinivas Mujumdar
Ranch Hand

Joined: Aug 27, 2004
Posts: 328
Hello,
I think you can specify the name of folder where you want to store uplodaed files as well as max. file size in <controller> tag of Struts-Config.xml. attributes are tempDir & maxFileSize is suppose.

I hope this helps
Shrinivas Mujumdar
sathish Havalige
Greenhorn

Joined: Nov 12, 2012
Posts: 1
Hello,
Am using file upload concept in my project, how to upload files from my computer to another computer please tel me if you know the answer
Nam Ha Minh
Ranch Hand

Joined: Oct 31, 2011
Posts: 484

sathish Havalige wrote:Hello,
Am using file upload concept in my project, how to upload files from my computer to another computer please tel me if you know the answer


Here is the tutorial you need: Upload file with Apache Common file upload


PM Me If You Want to get Urgent Help on Java Programming
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Struts file upload size limit
 
Similar Threads
Reg. File Upload
Large File Upload
commons-fileupload
FileUploadException
Receiving multipart request