Hello Jb,
i wasn't looking for the basic stuff... I tried this:
And yes i configured cm:property-paceholder from osgi config (Which is
working with reloading) but this here doesn't work
<camelContext>
<routeTemplate id="myTemplate">
<templateParameter name="name"/>
<templateParameter name="greeting"/>
<templateParameter name="myPeriod" defaultValue="3s"/>
<route>
<from uri="timer:{{name}}?period={{myPeriod}}"/>
<setBody><simple>{{greeting}} ${body}</simple></setBody>
<log message="${body}"/>
</route>
</routeTemplate></camelContext>
And in spring application.props you can do something like the following
what i added to the osgi config. Its quite handy when you want to create
multiple kafka consumer within one context e.g.
camel.route-template[0].template-id=myTemplatecamel.route-template[0].name=Jeancamel.route-template[0].greeting=cheese
camel.route-template[1].template-id=myTemplatecamel.route-template[1].name=Matthiascamel.route-template[1].greeting=wurst
Btw i had an outher Caml regarded question .. injecting karaf JAAS
into jetty and kubernetes clustering support.
BR,
Matthias
Am Mi., 7. Juli 2021 um 09:26 Uhr schrieb Jean-Baptiste Onofre <
[email protected]>:
> Hi Mathias,
>
> Is it what you are looking for:
> https://github.com/apache/karaf/tree/main/examples/karaf-camel-example/karaf-camel-example-blueprint
> ?
>
> Regards
> JB
>
> Le 6 juil. 2021 à 21:57, Matthias Leinweber <[email protected]>
> a écrit :
>
> Hello,
>
> i am trying to use routeTemplates within karaf with DSL but i don't find
> any examples how to create routes with XML DSL. Also
> https://camel.apache.org/manual/latest/route-template.html#_creating_routes_from_properties_file
> seems not wo work in karaf.
>
> Any suggestions?
>
> br,
> Matthias
>
>
>
--
Matthias Leinweber
Telefon: +49 176 810 24580
E-Mail: [email protected]
Internet: http://www.datatactics.de
datatactics GmbH, Sitz der Gesellschaft: Frankfurt am Main,
Registergericht: Amtsgericht Frankfurt am Main, HRB 121394, Geschäftsführer
Matthias Leinweber