1. Always appear java.lang.noclassdeffounderror:org/apache/commons/io/output/deferredfileoutputstream when doing file upload using struts2
So Google a bit, on-line 90% is said not to import Commons-io package, but I in the project is clearly already put this package imported,
There are also brothers said may be the version of the problem, but a few Commons-io version is still reported this error ah, I have been looking for two days this problem, the head hurts.
Because the project to use this upload, please master to save the younger brother.
Answer 1: Here The scripture is obvious,
1: You first confirm. is under the Web/lib.
2: Confirm whether there is also in the Tomcate project directory.
Answer 2: I also often have this situation,,, no mistake, is that the package is not published to the project go ...
Let's restart Eclipse and see if the bag is directly cuffed to Lib.
Answer 3: I also met with the landlord the same problem, after asked the elder, know is a packet conflict. But in my case I would like to say:
I used the file upload feature on the page, "Server internal error ..." In my "Tomcat Lib folder" and "Project directory Lib folder" Under all have commons-fileupload-1.2.jar bag, Elder told me is to remove Tomcat Lib folder of Commons-fileupload-1.2.jar. After I solved the problem, the landlord can try!
Answer 4: Should be commons-fileupload with Commons-io package version issue.
My project is Eclipse + Maven struts2.1.8 above methods have been tried. It's still not working.
The final version is updated to the newest 2.2.3.1 without the above problem.
Common bug summaries for web development