Get deserialized POST request body as map in aop advice?

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Get deserialized POST request body as map in aop advice?

Rj Ewing
I am using spring aop to wrap my jersey services to provide a way to do api versioning.

I am taking the requested resource version and transforming the request to the latest version, running the resource method, and then transforming the response to the requested version.

I am running into a bit of a problem accessing the request body params.

Is there a way in jersey to get the request body parameters that didn't map to a specific resource method param?

Ex.

Request body contains: "param1", "param2"

matching resource method contains params: "@FormParam("param1") String param1"

Is there a way to get "param2" from say the HttpServletRequest after jersey has read the input stream?