-
1. Re: CXF Interceptors for Logging
chubutin Aug 12, 2014 12:26 PM (in response to chubutin)I tried to modify the cxf.xml file inside the cxf-rt-core.jar in the folder /system/org/apache/cxf/cxf-rt-core/2.6.0.redhat-60024. This is my new configuration
code
code
But it doesn't take effect. I read in the CXF that this is the way to configure the bus. May be I'm wrong, can anyoue tell me if this is the way?
-
2. Re: CXF Interceptors for Logging
chubutin Aug 13, 2014 10:24 AM (in response to chubutin)CXF needs one property to configure all the CXF Buses that it creates when a CXF service is deployed. That property is
org.apache.cxf.logging.enabled=true
And you should put in system.properties
This is the solution I found
With this solution, the In request is logged as
-
ID: 2
Address: http://localhost:8181/cxf/serviceImpl
Encoding: UTF-8
Http-Method: POST
Content-Type: text/xml;charset=UTF-8
Headers: {accept-encoding=[gzip,deflate], connection=[keep-alive], Content-Length=[294], content-type=[text/xml;charset=UTF-8], Host=[localhost:8181], SOAPAction=[""], User-Agent=[Apache-HttpClient/4.1.1 (java 1.5)]}
Payload:
-
And the out
-
ID: 2
Response-Code: 200
Encoding: UTF-8
Content-Type: text/xml
Headers: {accept-encoding=[gzip,deflate], breadcrumbId=[ID-fluxit-ntb-43-48345-1407863723188-2-2], dynamicRouteByOperation=[direct:getserviceGET], Expires=[Wed, 31 Dec 1969 21:00:00 ART], Host=[localhost:8181], Server=[Apache-Coyote/1.1], Set-Cookie=[JSESSIONID=1C52CF757DE8385DCB829D8E7F572F55.tomcat2; Path=/apex], User-Agent=[Apache-HttpClient/4.1.1 (java 1.5)]}
Payload: