Hi,
I am using Camel Loop in router like below, please suggest any improvement
from("direct:terminateEvents")
.to("sql:select event_id from events where id = 32611 and status != 777")
.setProperty("totalEvents", simple("${body.size}") )
.setProperty("counter", simple("0") )
.loopDoWhile(simple("${property.counter} < ${property.totalEvents}"))
.to("sql:update ABC set status=333 where event_id =:${body[
${property.counter} ]}")
.setProperty("counter",simple("${property.counter}++") )
.end()
.to("direct:Nex")
.end();
--
View this message in context:
http://camel.465427.n5.nabble.com/Loop-in-Routers-tp5783506.html
Sent from the Camel - Users mailing list archive at Nabble.com.