Here's a file source endpoint definition:
String uri = "file:files" +
So consider this route:
With file endpoint definition above, it means, that with consume the files from some directory called "files", the initial delay for the files polling is 3 seconds, and we will poll with fixed intervals - 1 second, filtering out non-xml files.
In addition to that, if a file is processed successfully, it is being moved to a "backup" directory appending a time stamp in the file's name.
A new feature is a moveFailure attribute, which in case of failure in someProcessor or in the target endpoint ("someBean") allows you to handle the failed files, e.g. renaming or moving to another directory. At the time of writing the feature is available in snapshot version of Camel.