I am trying to integrate Apache CXF with Apache Camel.
Configuration for camel:
<cxf:cxfEndpoint id="authTest"
address="/cxfAuth"
serviceClass="com.test.AuthService" >
<cxf:properties>
<entry key="dataFormat" value="POJO" />
<entry key="setDefaultBus" value="true" />
</cxf:properties>
</cxf:cxfEndpoint>
<camel:camelContext trace="true">
<camel:route>
<camel:from uri="cxf:bean:authTest" />
<camel:to uri="bean:routeExitResponseProcessor"/>
</camel:route>
</camel:camelContext>
Now to invoke specific operation on web service I am using this:
<camel:route>
<camel:from uri="direct:startAuthTest"/>
<camel:setHeader headerName="getEmployee">
<camel:constant>gid</camel:constant>
</camel:setHeader>
<camel:to uri="cxf:bean:authTest" />
<camel:log message=">>> data is : ${body}"/>
<camel:to uri="bean:routeExitResponseProcessor"/>
</camel:route>
But after including above config I am getting WARN ServletController:149 - Can't find the the request for http://localhost:8080/CXFService/services/cxfAuth's Observer on the server console and my webservice is not found on browser.
Please help.
you can call the following to get the CXF operation name being called…see http://camel.apache.org/cxf.html for more details
also, see this unit test for example usage…
http://svn.apache.org/repos/asf/camel/trunk/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/CxfConsumerTest.java