Hello all, I just upgraded my webservices client from Axis1 to Axis2. With Axis1 I was able to log the HTTP requests and responses just by adding the following line to my log4j.properties
log4j.logger.org.apache.axis.transport.http=DEBUG and it created nice logs where all the body of the http request was shown using just one log (The content could be multiline, but there was just one call to the logger) 8C499036B8A58B99B6BDB01792F3C2897CD828A7 2012-04-17 08:26:28,575 DEBUG org.apache.axis.transport.http.HTTPSender - Enter: HTTPSender::invoke 8C499036B8A58B99B6BDB01792F3C2897CD828A7 2012-04-17 08:26:28,745 DEBUG org.apache.axis.transport.http.HTTPSender - XML sent: 8C499036B8A58B99B6BDB01792F3C2897CD828A7 2012-04-17 08:26:28,745 DEBUG org.apache.axis.transport.http.HTTPSender - --------------------------------------------------- 8C499036B8A58B99B6BDB01792F3C2897CD828A7 2012-04-17 08:26:28,745 DEBUG org.apache.axis.transport.http.HTTPSender - POST /aa HTTP/1.0 Content-Type: text/xml; charset=utf-8 Accept: application/soap+xml, application/dime, multipart/related, text/* User-Agent: Axis/1.4 Host: 180.213.103.133:83 Cache-Control: no-cache Pragma: no-cache SOAPAction: "aa:query:Query_6_0" Content-Length: 1878 <?xml version="1.0" encoding="UTF-8"?><soapenv:Envelope xmlns:soapenv=" http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd=" http://www.w3.org/2001/XMLSchema" xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance"><soapenv:Body>*** hidden ***</soapenv:Body></soapenv:Envelope> On Axis2 I changed the line to: log4j.logger.org.apache.axis2.transport.http=DEBUG But now Axis2 is using a bunch of calls to the logger to show the HTTP request and responses 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,007 DEBUG httpclient.wire.content - << "[\n]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,007 DEBUG httpclient.wire.content - << "</ns1:reasonDescription><ns1:statusCode>200</ns1:statusCode></ns1:statusHeader></ns1:queryReturn></ns1:queryResponse>" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,009 DEBUG httpclient.wire.content - << "[\r]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,009 DEBUG httpclient.wire.content - << "[\n]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,009 DEBUG httpclient.wire.content - << "0" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,009 DEBUG httpclient.wire.content - << "0" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,009 DEBUG httpclient.wire.content - << "2" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,009 DEBUG httpclient.wire.content - << "2" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,009 DEBUG httpclient.wire.content - << "[\r]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,009 DEBUG httpclient.wire.content - << "[\n]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "</soapenv:Body></soapenv:Envelope>" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "[\r]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "[\n]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "0" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "0" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "0" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "0" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "[\r]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "[\n]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "[\r]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.content - << "[\n]" 590AEACBF7F76E6912414FD0ED1AB0187543A98B 2012-05-21 21:59:47,010 DEBUG httpclient.wire.header - << "[\r][\n]" Is there any way to make it behave like it did with Axis1? Thanks