Hi

If the directories are from the same FTP server, you can use a filter
(implement as a java bean) and then decide true|false to dir1 or dir2
to accept.

On Fri, Nov 16, 2012 at 1:11 PM, Forsthofer, Franz
<franz.forstho...@sap.com> wrote:
> Hello,
>
> in my scenario I have to pull files via FTP consumer endpoint from two 
> directories dir1 and dir2. But the condition is that first all files from 
> directory dir1 shall be read before the files from dir2 are read.
>
> My first idea was to create two routes, one route with a FTP consumer 
> endpoint for directory dir1 and one route with a FTP consumer endpoint for 
> directory dir2 and that I control the starting and stopping of the consumers 
> in a custom RoutePolicy which is used by both routes. I tried this and this 
> works fine.
>
> However, I am wondering whether there is not a better way. Is it not possible 
> to have only one FTP consumer endpoint which can be stopped and reconfigured 
> without stopping the route? I know there is the possibility to add and remove 
> routes at runtime. But I do not want to "disturb" the route processing by 
> stopping the route.
>
> Regards Franz
>
>



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cib...@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Reply via email to