can a servlet have both soap request and simple request
Raj Kumar Bindal
Author and all-around good cowpoke
posted 9 years ago
In the servlet's doPost method check the content type (ServletRequest.getContentType()). For a SOAP message this will be "text/xml", "application/xml" or "application/soap+xml". If it is one of those types use ServletRequestgetInputStream() or ServletRequest.getParameter("DATA") to access the request body. Then check whether it contains a SOAP envelope. Using XPath is probably the easiest way of accomplishing this.