Hi The file component is intende for being used in routes, where it can work on batches of files.
The polling consumer API you do is for a single message at a time, and doesnt work as fast when the component is batch based. So if you really want to move files from one dir to another from java code, then write the java code using java.io.File API to do that. On Fri, May 24, 2013 at 10:30 AM, spilled_beverage < grahamduck...@yahoo.co.uk> wrote: > Hi Claus, > > Thanks for the reply (and congratulations on the Camel in Action book - > very > readable and a great intro to Camel). > > Setting maxMessagesPerPoll=1 works but slows down the run hugely (from 10 > seconds to around 10 minutes in my quick test). > Setting it to a higher value (e.g. 500) still works but runs quicker (back > to seconds). > However, setting it to a value such as 5000 causes the original problem - > not all files are moved. > Is this issue only when it is greater than the number of files? > Is there a reason why setting it to 0 (so no limit) fails when using the > ConsumerTemplate? > > Thanks for any pointers. > > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/ConsumerTemplate-for-large-number-of-files-tp5733037p5733072.html > Sent from the Camel - Users mailing list archive at Nabble.com. > -- Claus Ibsen ----------------- www.camelone.org: The open source integration conference. 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