Hi, I have an index file that lists a list of file names and each file needs
to be processed asynchronously. So I have a camel context with quartz timer
scheduled to trigger at X time (once a day).  Then within that route, I have
a split logic to split the file name list and each file is sent to SEDA
queue for asynchronous processing.  All works well so far.  Now I want to
find out when all files got processed.  So I tried this:

  <to uri=&quot;seda:fileProcessing?&lt;b>waitForTaskToComplete=Always*"/>

With this setup, each file processing gets sequential and I lose the
asynchronous behavior and it slows down the overall processing now. On the
consumer side, I have set the concurrentConsumers=5 but still it behaves
sequential.

Question:  If I set waitForTaskToComplete=Always in the producer side and I
set concurrentConsumers=5, will that make the overall processing behavior
sequential though I set concurrentConsumers > 0?  It seems like
waitForTaskToComplete takes precedence and nullfies the concurrentConsumers
setting.

How do I achieve async behavior by processing all files in parallel but I
want to wait for all SEDA queue processing is done before I say in the
quartz route that all processing is fully done for that execution?

Please provide some thoughts.

Thanks.



--
View this message in context: 
http://camel.465427.n5.nabble.com/waitForTaskToComplete-concurrentConsumers-tp5768446.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to