camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: process files in order
Date Thu, 19 Jul 2012 11:11:07 GMT
On Thu, Jul 19, 2012 at 9:14 AM, pvunckx <pieter.vunckx@telenet.be> wrote:
> Hi,
>
> What is the best practice for processing 4 files one after another? The
> second may only start when the first is completely processed.
> Ordering the files is not an issue, this is working.
>

This is the default behavior of the file consumer.

And if your connect routes with the direct component then its
synchronous as well.
So it should work processing in sequence.

You must do something in your routes that goes async / concurrent.

What do you do in your routes?


> For the moment I have 5 routes:
> - One for the file poller (with sorter)
> - 4 separate routes (direct) for each file (each has their own logic).
>
> When I run this, the files aren't processed in the right sequence...
>
> I was thinking in the direction of a wait-while (expression) thing but that
> doesn't exist (I think)....
>
> Someone has an idea how to handle this?
>
> Thx
> Pieter
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/process-files-in-order-tp5716234.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
FuseSource
Email: cibsen@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus, fusenews
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Mime
View raw message