camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Charles Moulliard <ch0...@gmail.com>
Subject Re: how to deploy a project with a CAMEL-XSTREAM in fuse fabric container
Date Fri, 11 Jul 2014 09:38:33 GMT
Your problem is related to the fact that this bundle -
org.apache.servicemix.bundles.xstream [131] ) is not able to find/load this
class --> org.xmlpull.v1.XmlPullParserException


On Fri, Jul 11, 2014 at 8:40 AM, Claus Ibsen <claus.ibsen@gmail.com> wrote:

> The xml file is that spring or blueprint?
>
> Favor blueprint as that generally works better with OSGi.
>
> On Thu, Jul 10, 2014 at 10:35 PM, aioria3077 <aioria3077@gmail.com> wrote:
> > they would greatly appreciate your help
> >
> > my exercise is to convert a CSV separated by "|" to a XML, in which I'm
> > using camel-bindy and camel-xstream,
> >
> > everything works fine if running with "mvn camel:run"
> >
> > I show my camel-context
> >
> > ...
> > ...
> > ...
> > <bean id="activemq"
> > class="org.apache.activemq.camel.component.ActiveMQComponent">
> >         <property name="brokerURL" value="tcp://localhost:61618"/>
> >         <property name="userName" value="admin"/>
> >         <property name="password" value="admin"/>
> >         </bean>
> >
> >   <camelContext xmlns="http://camel.apache.org/schema/spring">
> >
> >     <dataFormats>
> >         <bindy id="bindy" type="Csv"
> classType="com.cion.csvBindy.CSVtoXML"/>
> >         <xstream id="xstream">
> >                         <aliases>
> >                                 <alias name="movimiento"
> class="com.cion.csvBindy.CSVtoXML" />
> >                         </aliases>
> >         </xstream>
> >     </dataFormats>
> >
> >     <route>
> >       <from uri="file:work/input"/>
> >                 <split parallelProcessing="true" streaming="true">
> >             <tokenize token="\n" group="1"/>
> >             <log message="${body}"/>
> >             <to uri="activemq:colaSplit"/>
> >         </split>
> >     </route>
> >
> >     <route>
> >         <from uri="activemq:colaSplit"/>
> >         <log message="salida de la cola: ${body}"/>
> >         <unmarshal ref="bindy"/>
> >         <log message="despues de unmarshal: ${body}"/>
> >         <marshal ref="xstream"/>
> >         <log message="despues de marshal con Xstream: ${body}"/>
> >         <to uri="activemq:colaXML"/>
> >     </route>
> >
> > </camelContext>
> >
> > *REPEAT is working properly.*
> >
> > the problem comes when I have to deployar in a FUSE FABRIC CONTAINER
> >
> > for this I created a profile with the following characteristics:
> >
> > parents: mq-client, feature-camel
> >
> > features: camel, camel-spring, camel-core, camel-bindy, camel-xstream,
> > activemq-camel
> >
> > repositories: mvn:org.apache.activemq......../features
> >                    mvn:org.apache.camel.karaf......../features
> >
> > and the project as a bundle
> >
> > THE PROFILE IS PROVISIONED CORRECTLY, the "work / input" directory is
> > created within the container
> >
> > when I insert the file, this is spent correctly, the problem comes in the
> > second route right on the part of:
> >
> > <marshal ref="xstream"/>
> >
> > reviewing the log of the container, the error is as follows:
> >
> > 2014-07-10 13:23:56,497 | WARN  | sumer[colaSplit] |
> EndpointMessageListener
> > | rg.apache.camel.util.CamelLogger  224 | 113 -
> org.apache.camel.camel-core
> > - 2.12.0.redhat-610379 | Execution of JMS message listener failed. Caused
> > by: [java.lang.NoClassDefFoundError -
> org/xmlpull/v1/XmlPullParserException]
> > java.lang.NoClassDefFoundError: org/xmlpull/v1/XmlPullParserException
> >         at com.thoughtworks.xstream.XStream.<init>(XStream.java:350)
> >         at
> >
> org.apache.camel.dataformat.xstream.AbstractXStreamWrapper.createXStream(AbstractXStreamWrapper.java:79)
> >         at
> >
> org.apache.camel.dataformat.xstream.AbstractXStreamWrapper.getXStream(AbstractXStreamWrapper.java:66)
> >         at
> >
> org.apache.camel.dataformat.xstream.AbstractXStreamWrapper.marshal(AbstractXStreamWrapper.java:204)
> >         at
> >
> org.apache.camel.processor.MarshalProcessor.process(MarshalProcessor.java:81)
> >         at
> >
> org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:72)
> >         at
> >
> org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:398)
> >         at
> >
> org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)
> >         at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)
> >         at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)
> >         at
> >
> org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)
> >         at
> >
> org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:105)
> >         at
> >
> org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:87)
> >         at
> >
> org.apache.camel.component.jms.EndpointMessageListener.onMessage(EndpointMessageListener.java:103)
> >         at
> >
> org.springframework.jms.listener.AbstractMessageListenerContainer.doInvokeListener(AbstractMessageListenerContainer.java:562)[129:org.apache.servicemix.bundles.spring-jms:3.2.8.RELEASE_1]
> >         at
> >
> org.springframework.jms.listener.AbstractMessageListenerContainer.invokeListener(AbstractMessageListenerContainer.java:500)[129:org.apache.servicemix.bundles.spring-jms:3.2.8.RELEASE_1]
> >         at
> >
> org.springframework.jms.listener.AbstractMessageListenerContainer.doExecuteListener(AbstractMessageListenerContainer.java:468)[129:org.apache.servicemix.bundles.spring-jms:3.2.8.RELEASE_1]
> >         at
> >
> org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute(AbstractPollingMessageListenerContainer.java:325)[129:org.apache.servicemix.bundles.spring-jms:3.2.8.RELEASE_1]
> >         at
> >
> org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute(AbstractPollingMessageListenerContainer.java:263)[129:org.apache.servicemix.bundles.spring-jms:3.2.8.RELEASE_1]
> >         at
> >
> org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:1101)[129:org.apache.servicemix.bundles.spring-jms:3.2.8.RELEASE_1]
> >         at
> >
> org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.executeOngoingLoop(DefaultMessageListenerContainer.java:1093)[129:org.apache.servicemix.bundles.spring-jms:3.2.8.RELEASE_1]
> >         at
> >
> org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:990)[129:org.apache.servicemix.bundles.spring-jms:3.2.8.RELEASE_1]
> >         at
> >
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)[:1.7.0_25]
> >         at
> >
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)[:1.7.0_25]
> >         at java.lang.Thread.run(Thread.java:724)[:1.7.0_25]
> > Caused by: java.lang.ClassNotFoundException:
> > org.xmlpull.v1.XmlPullParserException not found by
> > org.apache.servicemix.bundles.xstream [131]
> >         at
> >
> org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1532)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]
> >         at
> >
> org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:75)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]
> >         at
> >
> org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:1955)[org.apache.felix.framework-4.0.3.redhat-610379.jar:]
> >         at
> java.lang.ClassLoader.loadClass(ClassLoader.java:357)[:1.7.0_25]
> >         ... 25 more
> >
> >
> >
> >
> > highlighting the following parts
> >
> >
> > Execution of JMS message listener failed. Caused by:
> > [java.lang.NoClassDefFoundError - org/xmlpull/v1/XmlPullParserException]
> >
> >
> > Caused by: java.lang.ClassNotFoundException:
> > org.xmlpull.v1.XmlPullParserException not found by
> > org.apache.servicemix.bundles.xstream [131]
> >
> > I searched and download the packages
> >
> > pull-parser-2.1.10
> > xmlpull-1.1.3.1
> > org.apache.felix.bundlerepository-1.6.6
> > org.apache.servicemix.bundles.xstream-1.3_3
> >
> >
> >
> > I have gotten as bundles to profile without any result
> >
> > could someone help me????   PLEASE
> >
> >
> >
> > --
> > View this message in context:
> http://camel.465427.n5.nabble.com/how-to-deploy-a-project-with-a-CAMEL-XSTREAM-in-fuse-fabric-container-tp5753655.html
> > Sent from the Camel - Users mailing list archive at Nabble.com.
>
>
>
> --
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> Email: cibsen@redhat.com
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen
> hawtio: http://hawt.io/
> fabric8: http://fabric8.io/
>



-- 
Charles Moulliard
Apache Committer / Architect @RedHat
Twitter : @cmoulliard | Blog :  http://cmoulliard.github.io

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message