On Tue, Nov 8, 2011 at 2:13 PM, wing-tung Leung <wingtung.le...@gmail.com>wrote:

> my camel context contains a few routes which should not be started
> automatically, but it should run a business check first for those routes.
> My initial idea is to disable "autoStartup" for those routes, and add a
> custom StartupListener which performs the check and simply calls
> "startRoute()" on the context if the check passes.
>

For your information, I found an easy workaround: I added an extra Spring
bean which implements the "ApplicationListener<ContextRefreshedEvent>"
interface, which fires up the relevant routes AFTER the complete
initialization of the Spring context.

Whether the StartupListener documentation/behavior is accurate, is another
discussion .. :-)

Reply via email to