camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From onders <ondersezgin+camelu...@gmail.com>
Subject Re: DefaultSqlPrepareStatementStrategy lookupParameter when onConsume used in SQL component
Date Thu, 07 Apr 2016 10:12:36 GMT
Hmm.. I think i misunderstood the route conceptually.

What i thought was that below is a single route;

from("sql:select rowid vrowid from myTable where nstatus = 0?outputClass=" +
MyBean.class.getName() 
                + "&onConsume=update myTable set nstatus = 1 where rowid =
:#${body.getVrowid()}") 
                               
.routeId("mySimpleRoute").threads(5).to("direct:generateLine").end(); 


and the exchange becomes complete when we do 

...
...
// piece of code above
.to("direct:generateLine").end();

and another route is 

from("direct:generateLine").process(new
LineGenerator()).to("amq:queue:jms.simpleQueue");

So i expected onConsume receives MyBean as the body of exchange;
But you are saying that exhange is complete after this line

>> from("direct:generateLine").process(new
>> LineGenerator()).to("amq:queue:jms.simpleQueue");

so onConsume receives whatever is set as the body of exchange in the
instance of LineGenerator.

I think i am confused?

Could you please help me understand what makes up the route?

Regards
├ľnder








--
View this message in context: http://camel.465427.n5.nabble.com/DefaultSqlPrepareStatementStrategy-lookupParameter-when-onConsume-used-in-SQL-component-tp5780437p5780663.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message