You can start it once and use it (that's the default way) over your complete application lifecycle. And you have not to start the route explicitly, but load them into the context.

Best regards - Claus

Am Freitag, den 03.06.2011, 08:47 +0200 schrieb ltomuno <ltom...@163.com>:
java code:
CamelContext context = new DefaultCamelContext();
... ...

        // start the route and let it do its work
        context.start();
        Thread.sleep(2000);
        // stop the CamelContext
        context.stop();
I have to do it every time?
start sleep stop
Is there a more elegant way to use CamelContext ?

Reply via email to