Java Code Examples for org.apache.cxf.feature.LoggingFeature#setPrettyLogging()
The following examples show how to use
org.apache.cxf.feature.LoggingFeature#setPrettyLogging() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: HelloWorldImplTest.java From cxf-jaxws with MIT License | 6 votes |
@BeforeClass public static void setUpBeforeClass() throws Exception { // start the HelloWorld service using jaxWsServerFactoryBean JaxWsServerFactoryBean jaxWsServerFactoryBean = new JaxWsServerFactoryBean(); // adding loggingFeature to print the received/sent messages LoggingFeature loggingFeature = new LoggingFeature(); loggingFeature.setPrettyLogging(true); jaxWsServerFactoryBean.getFeatures().add(loggingFeature); // setting the implementation HelloWorldImpl implementor = new HelloWorldImpl(); jaxWsServerFactoryBean.setServiceBean(implementor); // setting the endpoint jaxWsServerFactoryBean.setAddress(ENDPOINT_ADDRESS); jaxWsServerFactoryBean.create(); }
Example 2
Source File: HelloWorldImplTest.java From cxf-jaxws with MIT License | 6 votes |
@BeforeClass public static void setUpBeforeClass() throws Exception { // start the HelloWorld service using jaxWsServerFactoryBean JaxWsServerFactoryBean jaxWsServerFactoryBean = new JaxWsServerFactoryBean(); // adding loggingFeature to print the received/sent messages LoggingFeature loggingFeature = new LoggingFeature(); loggingFeature.setPrettyLogging(true); jaxWsServerFactoryBean.getFeatures().add(loggingFeature); // setting the implementation HelloWorldImpl implementor = new HelloWorldImpl(); jaxWsServerFactoryBean.setServiceBean(implementor); // setting the endpoint jaxWsServerFactoryBean.setAddress(ENDPOINT_ADDRESS); jaxWsServerFactoryBean.create(); }
Example 3
Source File: HelloWorldImplTest.java From cxf-jaxws with MIT License | 6 votes |
private static void createServerEndpoint() { JaxWsServerFactoryBean jaxWsServerFactoryBean = new JaxWsServerFactoryBean(); // create the loggingFeature LoggingFeature loggingFeature = new LoggingFeature(); loggingFeature.setPrettyLogging(true); // add the loggingFeature to print the received/sent messages jaxWsServerFactoryBean.getFeatures().add(loggingFeature); HelloWorldImpl implementor = new HelloWorldImpl(); jaxWsServerFactoryBean.setServiceBean(implementor); jaxWsServerFactoryBean.setAddress(ENDPOINT_ADDRESS); jaxWsServerFactoryBean.create(); }
Example 4
Source File: SoapCollectorTest.java From karaf-decanter with Apache License 2.0 | 6 votes |
@Before public void setup() throws Exception { JaxWsServerFactoryBean factory = new JaxWsServerFactoryBean(); LoggingFeature loggingFeature = new LoggingFeature(); loggingFeature.setPrettyLogging(true); factory.getFeatures().add(loggingFeature); TestServiceImpl testService = new TestServiceImpl(); factory.setServiceBean(testService); factory.setAddress("http://localhost:9090/test"); cxfServer = factory.create(); cxfServer.start(); while (!cxfServer.isStarted()) { Thread.sleep(200); } }