Entity lost when using application/x-www-form-urlencoded media type and 
FormParam
---------------------------------------------------------------------------------

                 Key: WINK-35
                 URL: https://issues.apache.org/jira/browse/WINK-35
             Project: Wink
          Issue Type: Bug
          Components: Server
    Affects Versions: 0.1
            Reporter: Jesse Ramos
            Priority: Minor


When using the application/x-www-form-urlencoded media type, if a resource 
method uses the FormParam annotation for one parameter and specifies an entity 
parameter, the entity parameter value is lost before being injected.  This is a 
sample method header:

        @POST
        @Path("withOneKeyAndEntity")
        public String getRes(@FormParam("firstkey") String firstKey,
                             MultivaluedMap<String, String> entity)

When obtaining the value for the FormParam parameter, the entity is read from 
the input stream.  When the input stream is later read for the entity parameter 
the entity is no longer on the input stream.  The read is done in the 
FormMultivaluedMapProvider entity provider.

This is an edge case because it's not likely that a user will use the FormParam 
to get the values of form parameters and also get all the parameters in the 
entity MultivaluedMap paramter.  However, technically it should be supported.

Will upload a patch.

-- 
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