2

I am trying to use @RequestBody annotation in one of my controllers method:

@Auditable(application = AuditApplication.DEP_TRXN, actionCategory = AuditActionCategory.READ_RESPONSE, actionDetail = "Viewed a tracking group.", event = AuditEventType.ACTION)
@RequestMapping(value = "groupView", method = RequestMethod.POST, produces = "application/json")
public @ResponseBody
String ajaxGroupView(@RequestBody String payload, final HttpServletRequest request) throws TrackingServiceException, JsonGenerationException, JsonMappingException,
        IOException
{

    String requestBody = java.net.URLDecoder.decode(payload, "UTF-8");
    return requestBody;
}

When i run this code on Jetty server my 'payload' gets the post data, but when i run the same code on Websphere Application Server -8, payload is 'null'. I have mvc annotation driven turn on. How do i make this code work on Websphere Application Server?

Thanks!

Karthik
  • 83
  • 1
  • 1
  • 7

0 Answers0