On Tue, Mar 25, 2014 at 10:00 AM, Donald Whytock <dwhyt...@apache.org>wrote:
> On Tue, Mar 25, 2014 at 7:32 AM, ibcole...@gmail.com <ibcole...@gmail.com > >wrote: > > > I'm trying to do something which seems like it should be very simple, but > > instead is turning out to be very difficult. > >[...] > > Were you including images in that email? Images and attachments often > don't make it on the mailing list. > > Don > Hi Don, Sorry, I think Nabble ate my code snippets because they were enclosed in xml. Let me try that again: The client is: <bean id="camelRouting" class="com.wireandwheel.demonstrations.ws.routes.ServerRoutes"/> <cxf:rsClient id="wmataBusLineSvc" address="http://api.wmata.com/Bus.svc/json/jRoutes?api_key=kfgpmgvfgacx98de9q3xazww" serviceClass="com.wireandwheel.demonstrations.ws.service.RemoteService" loggingFeatureEnabled="true" skipFaultLogging="true"> </cxf:rsClient> <!-- The camel route context --> <camel:camelContext xmlns="http://camel.apache.org/schema/spring"> <contextScan/> <camel:template id="camelTemplate"/> <camel:routeBuilder ref="camelRouting"/> </camel:camelContext> And the route is: from("timer:aTimer?fixedRate=true&period=10s") .setHeader(Exchange.HTTP_METHOD, constant("GET")) .to("cxfrs://bean://wmataBusLineSvc") .to("bean:itemRetriever") .to("log:com.wireandwheel.demonstrations?level=INFO") .process(aProcessor); I was able to get it working by switching from cxf to http4: from("timer:aTimer?fixedRate=true&period=10s") .setHeader(Exchange.HTTP_METHOD, constant("GET")) .to("http4:// api.wmata.com/Bus.svc/json/jRoutes?api_key=kfgpmgvfgacx98de9q3xazww") .unmarshal("json") .to("bean:wmataRoutes") .to("log:com.wireandwheel.demonstrations?level=INFO") .process(aProcessor);