camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Krystian <>
Subject Re: Delayer and asyncDelayed - how to delay asynchronously
Date Fri, 05 Nov 2010 23:59:53 GMT

I've tried doing something I did with 1.x version of camel, calling a method
to figure out the delay.
I can't get that to work though:

    <bean id="delayer" class="my.DelayerBean"/>

 <camel:camelContext id="camel5">
    <!--<camel:routeBuilder ref="redevTest" />-->
         <camel:from uri="activemq:redeliveryQueue"/>
                 <camel:method ref="delayer" method="sendAtTime"/>
         <camel:to uri="activemq:testQueue"/>

package my

class DelayerBean {
    public long sendAtTime() {
        return System.currentTimeMillis() + 10000

There's no delay and if I put a breakpoint in the method I will never get
there. It's not called.

I've tried changing the <method> to:
 <camel:method bean="delayer" method="sendAtTime"/>
 <camel:method bean="my.DelayerBean" method="sendAtTime"/>

same thing, function is never called.

Any tips?

View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message