You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Jarmo Sorvari <ja...@tamk.fi> on 2015/05/06 17:54:05 UTC

file2: recursive, delete, directories remain?

(Camel 2.12.3)

Hi!

Could someone confirm that this is not possible: scan source directory recursively with delete=true, but only files are deleted and subdirectories remain.

I think I ran into a race condition when trying to set this up: more files were being fed to the subdirectory that Camel was trying to delete.

Thanks in advance!

Jarmo Sorvari
Tampere University of Applied Sciences
Finland

RE: file2: recursive, delete, directories remain?

Posted by Jarmo Sorvari <ja...@tamk.fi>.
> The delete is only for files. Camel do not delete directories.


OK, thanks. I will have to remake the test to see what was happening...

Jarmo


> On Wed, May 6, 2015 at 5:54 PM, Jarmo Sorvari <ja...@tamk.fi>
> wrote:
> > (Camel 2.12.3)
> >
> > Hi!
> >
> > Could someone confirm that this is not possible: scan source directory
> recursively with delete=true, but only files are deleted and subdirectories
> remain.
> >
> > I think I ran into a race condition when trying to set this up: more files were
> being fed to the subdirectory that Camel was trying to delete.
> >
> > Thanks in advance!
> >
> > Jarmo Sorvari
> > Tampere University of Applied Sciences Finland
> 
> 
> 
> --
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> Email: cibsen@redhat.com
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen
> hawtio: http://hawt.io/
> fabric8: http://fabric8.io/

Re: file2: recursive, delete, directories remain?

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

The delete is only for files. Camel do not delete directories.

On Wed, May 6, 2015 at 5:54 PM, Jarmo Sorvari <ja...@tamk.fi> wrote:
> (Camel 2.12.3)
>
> Hi!
>
> Could someone confirm that this is not possible: scan source directory recursively with delete=true, but only files are deleted and subdirectories remain.
>
> I think I ran into a race condition when trying to set this up: more files were being fed to the subdirectory that Camel was trying to delete.
>
> Thanks in advance!
>
> Jarmo Sorvari
> Tampere University of Applied Sciences
> Finland



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/

Re: file2: recursive, delete, directories remain?

Posted by Shreyas Purohit <sh...@hotmail.com>.
Camel does not delete subdirectories, delete=true deletes only files. 

If you want to delete subdir, then add an onComplete on route and delete on success yourself. 

-Shreyas Purohit

On May 6, 2015 8:54 AM, Jarmo Sorvari <ja...@tamk.fi> wrote:
>
> (Camel 2.12.3) 
>
> Hi! 
>
> Could someone confirm that this is not possible: scan source directory recursively with delete=true, but only files are deleted and subdirectories remain. 
>
> I think I ran into a race condition when trying to set this up: more files were being fed to the subdirectory that Camel was trying to delete. 
>
> Thanks in advance! 
>
> Jarmo Sorvari 
> Tampere University of Applied Sciences 
> Finland