I like to create a route template with a parameter of a specific Java type.
For example the following routetemplate: routeTemplate("mypollenrich") .templateParameter("timeout","5000") .from("direct:in") .pollEnrich("myuri", "{{timeout}}","CurrentEnrichStrategy") .to("direct:out"); The above routetemplate is not accepted because the parameter "{{timeout}}" is a String, while a long is expected. Is it possible to pass the parameter as a long (and in general just any Java type)? I now tried to parse the String as Long like this: routeTemplate("mypollenrich") .templateParameter("timeout","5000") .from("direct:in") .pollEnrich("myuri", Long.parseLong("{{timeout}}"),"CurrentEnrichStrategy") .to("direct:out"); But doesn't seem allowed. What is the correct way of doing it? Raymond