Hi, I need to log the content of incoming soap messages in Axis2, BEFORE any kind of elaboration from Axis2(for example, I need to log the message also if it isn't well-formed, or the Security Header is invalid). Is there a way to simply do this, for example enabling debug log for a particular Axis2 class/package? I've tried to enable debug for the whole org.apache package and I'm quite surprised that, in tons of log, the SOAP message is never printed!
Also, I need to enable XSD validation (in particular, validation of soap-body content based on WSDL) for the incoming messages, that it seems disabled by default in Axis2. Any idea?
It is a possibile solution, but I hope there is a more simple solution that doesn't imply writing a custom module. It is quite strange that logging of SOAP messages and schema validation are not embedded in a product that was designed to work with webservices and XML/SOAP!
By the way, custom handlers work at "MessageContext" level, and in this object, the SOAP message was already parsed and available as SOAPEnvelope Axiom object. In this case a non-well formed XML cannot be read and logged. I think the logging should be done at transport (http request) level.
In the second case, validating the XML in an handler is difficult because I don't think that the WSDL is referenced by the messageContext...
subject: Axis2: Incoming SOAP messages: logging and validation