You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by cflockhart <cr...@gmail.com> on 2013/09/05 09:17:35 UTC

Using an Expression for the delayer in the Scala DSL

Hi,
It seems that only a fixed Period for the delay can be used in the Scala
DSL. I want to have different values for test and production (a 1 hour
message delay is no good when running unit tests). It's possible to use an
expression in the Java DSL though.. so is one way to do this to override
onJavaBuilder() and define the route in that method instead of using the
Scala DSL?

thanks



--
View this message in context: http://camel.465427.n5.nabble.com/Using-an-Expression-for-the-delayer-in-the-Scala-DSL-tp5738729.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Using an Expression for the delayer in the Scala DSL

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

Yeah whatever works for you. Please log a JIRA and work on a patch, so
we can have this improved in a release.

On Thu, Sep 5, 2013 at 10:37 AM, cflockhart <cr...@gmail.com> wrote:
> I'm using Camel 2.11.1.
> I'd looked at the 2.11 branch and it didn't look too hard to add it so I'll
> have a go at a patch. However, if we want to use  a released version of
> Camel, is the approach of overriding onJavaBuilder() the way to go?
>
> thanks!
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Using-an-Expression-for-the-delayer-in-the-Scala-DSL-tp5738729p5738742.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: Using an Expression for the delayer in the Scala DSL

Posted by cflockhart <cr...@gmail.com>.
I'm using Camel 2.11.1. 
I'd looked at the 2.11 branch and it didn't look too hard to add it so I'll
have a go at a patch. However, if we want to use  a released version of
Camel, is the approach of overriding onJavaBuilder() the way to go?

thanks!



--
View this message in context: http://camel.465427.n5.nabble.com/Using-an-Expression-for-the-delayer-in-the-Scala-DSL-tp5738729p5738742.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Using an Expression for the delayer in the Scala DSL

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

What version of Camel do you use?

There may be room for improvement in the Scala DSL. As we love
contributions you are welcome to dive into the code base of
camel-scala and provide patches to add such functionality.

http://camel.apache.org/contributing.html

Also you are welcome to log a JIRA ticket for this improvement


On Thu, Sep 5, 2013 at 9:17 AM, cflockhart <cr...@gmail.com> wrote:
> Hi,
> It seems that only a fixed Period for the delay can be used in the Scala
> DSL. I want to have different values for test and production (a 1 hour
> message delay is no good when running unit tests). It's possible to use an
> expression in the Java DSL though.. so is one way to do this to override
> onJavaBuilder() and define the route in that method instead of using the
> Scala DSL?
>
> thanks
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Using-an-Expression-for-the-delayer-in-the-Scala-DSL-tp5738729.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen