I have multiple client machines that are processing and sending JSON (Post HTTP) to a central machine. The Central machine is running a Java Servlet and taking the HttpServletRequest variable (request) and doing a request.getReader() and pushing it to a string, which I later parse into a JSON Object.
Before I even get to parse into the JSON Object I sometimes get data corruption from the HttpServletRequest variable, where the JSON string has some previous data from another scanner, seems like the buffer wasn't cleared or something. I did confirm on the client machine that the data being sent out is correct.
- Is there anything obvious on Java Servlets with DoPost that I might need to do? I wouldn't think there would be a need for synchronization.
- Is there a way to see the full HTTP body within Tomcat without using a sniffer?