Question

I would like to dump the soap requests and responses to the console.

I have tried setting up log4:

log4j.logger.httpclient.wire=DEBUG, CARBON_CONSOLE
log4j.logger.org.apache.commons.httpclient=DEBUG, CARBON_CONSOLE

However, this isn't logging any soap requests/responses.

Was it helpful?

Solution

I don't think you can do this with Log4J properties. I enabled TRACE for like following,

log4j.logger.org.apache.axis2.builder=TRACE log4j.logger.org.apache.axis2.transport.http.ApplicationXMLFormatter=TRACE log4j.logger.org.apache.axis2.transport.http.SOAPMessageFormatter=TRACE

Still you can't get the SOAP messages going in and out. If you're playing around with ESB then of course you can use the Log mediator in inSequence and outSequence to get the SOAP request/response

Easiest way would be to use a tool like TCPMon (shipped with all the WSO2 products and can be found in the bin folder) or SOAP UI.

OTHER TIPS

Changing the logging in wso2 might help. Go to Configure->Logging, and set the org.apache.axis2.transport.local.LocalTransportReceiver, org.apache.axis2.transport.local.LocalTransportSender, org.apache.axis2.transport.local.LocalResponder to the DEBUG level. It will end up in the in the repository/logs/wso2carbon.log

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top