Check the casing of your CXF bean ids. Spring is case sensitive.
On 5 Feb 2013 20:41, "Hariprasath Manivannan" <jdev.h...@gmail.com> wrote:

> Hi,
>
> I am having the followig end points
>
>
> <beans xmlns="http://www.springframework.org/schema/beans";
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> xmlns:cxf="http://camel.apache.org/schema/cxf";
> xsi:schemaLocation="http://www.springframework.org/schema/beans
> http://www.springframework.org/schema/beans/spring-beans.xsd
> http://camel.apache.org/schema/cxf
>   http://camel.apache.org/schema/cxf/camel-cxf.xsd
>   http://cxf.apache.org/jaxrs http://cxf.apache.org/schemas/jaxrs.xsd";>
>
> <import resource="classpath:META-INF/cxf/cxf.xml"/>
> <cxf:cxfEndpoint id="App1Endpoint"
> address="http://myserver:9084/App_service_facade/services/Service1";
> serviceClass="com.example.ServiceOne"
> />
>
> <cxf:rsClient id="App2EndPoint" address="
> http://myserver:9084/App_service_facade/services/Service2";
> serviceClass="com.example.ServiceTwo"/>
> </beans>
>
>
> and the following routes
>
> <beans xmlns="http://www.springframework.org/schema/beans";
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> xsi:schemaLocation="http://www.springframework.org/schema/beans
> http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
> http://camel.apache.org/schema/spring
>   http://camel.apache.org/schema/spring/camel-spring.xsd
>   http://cxf.apache.org/jaxrs http://cxf.apache.org/schemas/jaxrs.xsd";>
>
> <import resource="classpath:camel/camel-endpoints-context.xml" />
>
>         <bean id="Processor1" class="com.example.Processor1"/>
> <bean id="Processor2" class="com.example.Processor2"/>
>  <camelContext xmlns="http://camel.apache.org/schema/spring";>
> <route>
> <from uri="direct:performMatch"/>
> <process ref="Processor1"/>
> <to uri="cxf:bean:App1Endpoint"/>
> <!-- <process ref="Processor2"/> -->
> <to uri="cxfrs:bean:App2Endpoint"/>
> </route>
> </camelContext>
> </beans>
>
> So I am trying to invoke two webservice, one after another. The first one
> is SOAP and the second one is restful. If I dont have the restful service
> invocation, the route works. However with the above route, I get the
> following exception during server startup
>
> Caused by: org.apache.camel.NoSuchBeanException: No bean could be found in
> the registry for: App2Endpoint of type:
> org.apache.cxf.jaxrs.AbstractJAXRSFactoryBean
> at
>
> org.apache.camel.util.CamelContextHelper.mandatoryLookup(CamelContextHelper.java:130)
> at
>
> org.apache.camel.component.cxf.jaxrs.CxfRsComponent.createEndpoint(CxfRsComponent.java:55)
> at
>
> org.apache.camel.impl.DefaultComponent.createEndpoint(DefaultComponent.java:91)
> at
>
> org.apache.camel.impl.DefaultCamelContext.getEndpoint(DefaultCamelContext.java:461)
>
> I've been stuck on this for days. Any pointers please.
>
> Thanks,
> Hari
>

Reply via email to