...
Name | Value |
---|---|
inInterceptors | The interceptors contributed to inbound message interceptor chains. A list of <bean>s or <ref>s. |
inFaultInterceptors | The interceptors contributed to inbound fault interceptor chains. A list of <bean>s or <ref>s. |
outInterceptors | The interceptors contributed to outbound message interceptor chains. A list of <bean>s or <ref>s. |
outFaultInterceptors | The interceptors contributed to outbound fault interceptor chains. A list of <bean>s or <ref>s. |
features | The features applied to the bus. A list of <bean>s or <ref>s. See here for a list of available features. |
...
Configuration using Java code
Although usually less convenient, interceptors can be added to the bus with using Java code. See this code sample for an example.Given an EndpointImpl object, the
bus can be accessed (and interceptors added) as follows:
Code Block |
---|
import javax.xml.ws.Endpoint;
import org.apache.cxf.interceptor.LoggingInInterceptor;
import org.apache.cxf.interceptor.LoggingOutInterceptor;
import org.apache.cxf.jaxws.EndpointImpl;
Object implementor = new GreeterImpl();
EndpointImpl ep = (EndpointImpl) Endpoint.publish("http://localhost/service", implementor);
ep.getServiceFactory().getBus().getInInterceptors().add(new LoggingInInterceptor());
ep.getServiceFactory().getBus().getOutInterceptors().add(new LoggingOutInterceptor());
|
Extending the Bus
TODO: Explain how to add a custom bus extension (META-INF/cxf/cxf.extension ...).