On Thu, Mar 5, 2009 at 5:31 PM, Bruce Snyder <bruce.sny...@gmail.com> wrote: > On Wed, Mar 4, 2009 at 10:54 PM, Willem Jiang <willem.ji...@gmail.com> wrote: >> Hi Bruce, >> >> If you already has the request message from the file endpoint, you just >> need to use http endpoint to call the external web service like this. >> >> <camelContext xmlns="http://activemq.apache.org/camel/schema/spring"> >> <package>com.mycompany.camel</package> >> <route> >> <from uri="file:src/data?noop=true"/> >> <to uri="http://localhost:9002/HelloWorld"/> >> </route> >> </camelContext> > > Thanks for the advice, Willem. I incorrectly assumed that the > camel-cxf module must be used to invoke a web service. > > The invocation is now working with the following route: > > <route> > <from uri="file:src/data?noop=true"/> > <to uri="http://localhost:9002/HelloWorld"/> > <to uri="log:HELLO_WORLD"/> > </route> > > However, it's invoking the web service twice - I'm seeing output from > two invocations of the web service: > > sayHi called > sayHi called > > Any idea why it's invoking it twice instead of just once? I have before been tricked by log4j if you have it defined twice as a appender. Could it be that?
Or do you have 2 files in the folder? > > Bruce > -- > perl -e 'print > unpack("u30","D0G)u8...@4vyy9&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*" > );' > > Apache ActiveMQ - http://activemq.apache.org/ > Apache Camel - http://camel.apache.org/ > Apache ServiceMix - http://servicemix.apache.org/ > > Blog: http://bruceblog.org/ > -- Claus Ibsen Apache Camel Committer Open Source Integration: http://fusesource.com Blog: http://davsclaus.blogspot.com/