camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Taariq Levack <>
Subject Re: How 2 catch infinite polling on a single file
Date Thu, 17 Nov 2011 18:30:58 GMT

Are you lucky enough to use 2.9?
If so just set the option sendEmptyMessageWhenIdle=true, see [1].
Else you need a polling strategy.



On 17 Nov 2011, at 7:47 PM, szaruba <> wrote:

> Hi everybody!
> After we implemented our routes based on ideas, described in the forum post
> we got a big problem. Basically we have 2 Camel routes, one of these routes
> is always asking (polling) for a single file.
> Our route looks like this:
> from("Path and filename to current file to grab")
> .routeId("batch")
> .to("file:data/outbox/")
> .convertBodyTo(String.class)
> .process(......);
> We got a list of files, and we have to transfer every of these files. Every
> file gets processed, but if there is a file in the list, that doesn’t exist
> in our input directory, the route is polling infinite for this file. Output
> of the consumer (this goes infinite): 
> "Took 0.0145 seconds to poll .............."
> If this happens we want to throw an exception or generate a syslog message,
> but the problem is, that we don't know how to implement such. Sure we can
> watch after the Log4j output, but this doesn't seem to be a convenient
> solution. If anybody has any hints, how to monitor, that a file was missing
> and a route is polling for infinite, please answer to this post. Thanks in
> advance. 
> Greetings, Lukas
> --
> View this message in context:
> Sent from the Camel - Users mailing list archive at

  • Unnamed multipart/alternative (inline, 7-Bit, 0 bytes)
View raw message