-
1. Re: fileUpload component - Strange behavior
carlabramsson Nov 9, 2007 8:05 AM (in response to jtsimikas)We are having some strange and sporadic errors with the fileupload component in 1.2.0 and 1.2.1 GA too. We loose the viewstate sometimes on some of the pages.
After some debugging, it seems like the problem is with the class that parses the multipart-request and not the UI-component. We noticed this after first removing the UI-compoent from the page, still errors, and then removing the enctype="multipart/form-data" from the form tag. After this, the error never occurs.
Most of the time no exception is thrown, the multipart parser just don't return ANY params at all. Sometimes it only omits the viewstate param. Sometimes it works. Sometimes this expection is thrown:18:13:08,233 ERROR [ExceptionFilter] exception root cause java.lang.ArrayIndexOutOfBoundsException: 2048 at org.jboss.seam.web.MultipartRequest.checkSequence(MultipartRequest.java:466) at org.jboss.seam.web.MultipartRequest.parseRequest(MultipartRequest.java:333) at org.jboss.seam.web.MultipartRequest.getParam(MultipartRequest.java:507) at org.jboss.seam.web.MultipartRequest.getParameterValues(MultipartRequest.java:579) at javax.servlet.ServletRequestWrapper.getParameterValues(ServletRequestWrapper.java:188) [clipped]
(2048 is the size of the buffer in MultipartRequest, fishy...)
So it's very hard to reproduce as it seems like the error only occurs when the size of the post request is at a specific size and contains a specific number of parameters or something. But I have one view/entity that the error occurs on every time, this eases the debugging...
You are probably seeing the same error, the missing validateForm() could be a result of the viewstate-param not being parsed.
I'm going to use the MultipartRequest-class from Seam 2.0 since it's changed a bit and see if the problem goes away.
(Using Myfaces 1.1.5, Seam 1.2.1GA, Latest stable JBoss RichFaces/Ajax4JSF, removed tomahawk, put the seam-filter first) -
2. Re: fileUpload component - Strange behavior
shane.bryzak Nov 11, 2007 8:52 PM (in response to jtsimikas)There were some file upload bugs that were fixed for 2.0.0, both in MultipartRequest and in the JSF control. I suggest trying this new version, and if these issues persist please let me know.
-
3. Re: fileUpload component - Strange behavior
kal-el Jan 9, 2008 6:57 AM (in response to jtsimikas)hi,
i would be very grateful if anyone could tell me if they found a workaround for that problem coz i'm experiencing the same thing and don't have a clue how to solve it.
thanks in advance. -
4. Re: fileUpload component - Strange behavior
shane.bryzak Jan 9, 2008 7:41 PM (in response to jtsimikas)"kal-el" wrote:
hi,
i would be very grateful if anyone could tell me if they found a workaround for that problem coz i'm experiencing the same thing and don't have a clue how to solve it.
thanks in advance.
Which version of Seam are you using?