https://issues.apache.org/bugzilla/show_bug.cgi?id=49711

           Summary: HttpServletRequest#getParts() does not work in a
                    Filter
           Product: Tomcat 7
           Version: 7.0.0
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Servlet & JSP API
        AssignedTo: dev@tomcat.apache.org
        ReportedBy: bal...@gmail.com


In order to have the ability to process multipart/form-data transparently with
help of the new Servlet 3.0 HttpServletRequest#getParts(), a Filter is the most
suitable place for this. 

This works fine in Glassfish v3. However, in Tomcat the getParts() returns null
and it works only inside a servlet with @MultipartConfig annotation.

This is too strict. This makes it hard if not impossible to process
multipart/form-data requests transparently with help of a Filter (i.e. creating
a new parametermap and replacing the original one in HttpServletRequest).

It is true that the Servlet 3.0 spec tells nothing about the use of this method
inside a Filter, but this is in my opinion an oversight. There is no other way
to obtain the parts than parsing the stream yourself with good 'ol Apache
Commons FileUpload.

Since it works fine in Glassfish v3, I'd suggest to make Tomcat 7 that lenient
as well.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to