[ 
https://issues.apache.org/jira/browse/TOMAHAWK-1305?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12635713#action_12635713
 ] 

Gertjan van Oosten commented on TOMAHAWK-1305:
----------------------------------------------

Hmm, tricky...  Good analysis though! ;-)

A quick check in my environment shows that you can't rely on any order of the 
post parameters in the multipart/form-data request; in my first (and only) 
testcase the MIME parts were in this order:
- an input parameter
- the file data
- the save button of the form
- a parameter named myForm_SUBMIT with value 1
- a parameter named myForm:_icdl with empty value
- the parameter javax.faces.ViewState

If the ViewState comes after the file part and the request is aborted during 
the upload when that part is too large, you will certainly not be able to know 
the value of ViewState parameter.
I have currently no idea how to solve this in a user friendly way.  E.g. 
processing the entire upload even though it is way too large and only throwing 
the error after the complete upload has finished forces the user to wait longer 
than necessary.


> No error when file is uploaded larger than uploadMaxFileSize
> ------------------------------------------------------------
>
>                 Key: TOMAHAWK-1305
>                 URL: https://issues.apache.org/jira/browse/TOMAHAWK-1305
>             Project: MyFaces Tomahawk
>          Issue Type: Bug
>          Components: File Upload
>    Affects Versions: 1.1.7-SNAPSHOT
>            Reporter: Gertjan van Oosten
>
> When a file is uploaded that is larger than the uploadMaxFileSize, the upload 
> is ignored but no error is shown.
> Reproducible with the fileupload example:
>   http://www.irian.at/myfacesexamples/fileupload.jsf
> Be patient, you need a file larger than 100 MBytes.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to