Charles,

In the current 3.2.1 release, servicemix-camel includes Camel 1.2. Haven't checked or anything, but I guess this method just isn't there in that release. Adding a newer version of Camel to you SU jar file won't make a difference because of the different classloaders involved (cfr. http://servicemix.apache.org/classloaders.html). The easiest way to solve this would be to build ServiceMix locally yourself and modify the Camel version (it is in the root pom.xml) in there to 1.3-SNAPSHOT. There should be a new release for ServiceMix fairly soon and we are trying to get Camel 1.3 in there as well.

Gert

cmoulliard wrote:
Hi,

When I deploy a Camelcontext project as an JBI endpoint in ServiceMix3, I
receive the following error ?
<loc-message>org.springframework.beans.factory.BeanCreationException: Error
crea
ting bean with name 'camel3:beanPostProcessor': Cannot resolve reference to
bean 'camel3' while setting bean property 'c
amelContext'; nested exception is
org.springframework.beans.factory.BeanCreationException: Error creating bean
with name
 'camel3': Invocation of init method failed; nested exception is
java.lang.NoSuchMethodError: org.apache.camel.model.Rou
teType.unmarshal()Lorg/apache/camel/builder/DataFormatClause;</loc-message>
<stack-trace><![CDATA[org.apache.xbean.kernel.ServiceRegistrationException:
org.
springframework.beans.factory.BeanCreationException: Error creating bean
with name 'camel3:beanPostProcessor': Cannot re
solve reference to bean 'camel3' while setting bean property 'camelContext';
nested exception is org.springframework.bea
ns.factory.BeanCreationException: Error creating bean with name 'camel3':
Invocation of init method failed; nested excep
tion is java.lang.NoSuchMethodError:
org.apache.camel.model.RouteType.unmarshal()Lorg/apache/camel/builder/DataFormatCla
use;
        at
org.apache.xbean.kernel.standard.ServiceManagerRegistry.registerService(ServiceManagerRegistry.java:424)
        at
org.apache.xbean.kernel.standard.StandardKernel.registerService(StandardKernel.java:220)
        at
org.apache.xbean.server.spring.loader.SpringLoader.load(SpringLoader.java:152)
        at
org.apache.servicemix.common.xbean.AbstractXBeanDeployer.deploy(AbstractXBeanDeployer.java:83)
        at
org.apache.servicemix.camel.CamelSpringDeployer.deploy(CamelSpringDeployer.java:79)
        at
org.apache.servicemix.common.BaseServiceUnitManager.doDeploy(BaseServiceUnitManager.java:88)
        at
org.apache.servicemix.common.BaseServiceUnitManager.deploy(BaseServiceUnitManager.java:69)
        at
org.apache.servicemix.jbi.framework.DeploymentService.deployServiceAssembly(DeploymentService.java:508)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.updateServiceAssembly(AutoDeploymentService.java:35
0)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.updateArchive(AutoDeploymentService.java:253)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.monitorDirectory(AutoDeploymentService.java:647)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService.access$800(AutoDeploymentService.java:60)
        at
org.apache.servicemix.jbi.framework.AutoDeploymentService$1.run(AutoDeploymentService.java:611)
        at java.util.TimerThread.mainLoop(Timer.java:512)
        at java.util.TimerThread.run(Timer.java:462)

REMARK :
-The camelcontext project work well in standalone.
- I have added the following dependencies in my POM.xml file :

                <dependency>
                        <groupId>org.apache.camel</groupId>
                        <artifactId>camel-core</artifactId>
                        <version>1.3-SNAPSHOT</version>
                </dependency>
                <dependency>
                        <groupId>org.apache.camel</groupId>
                        <artifactId>camel-jms</artifactId>
                        <version>1.3-SNAPSHOT</version>
                </dependency>

Regards,

Charles

Reply via email to