camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <>
Subject Re: Camel velocity template internationalization
Date Thu, 21 Mar 2013 09:16:16 GMT
On Wed, Mar 20, 2013 at 11:13 PM, paramjyotsingh
<> wrote:
> I have a scenario where I need to pick velocity based on locale. I have two
> problems for this.
> Do we any option in velocity endpoint to provide locale information? if not,
> do we have option in camel to set some header property in Exchange message
> so that velocity template gets picked up automatically for that locale.
> For example, suppose we have following velocity template files:
>  - email.vm
>  - en_email.vm
>  - cn_email.vm
>  - fr_email.vm
> if locale/language code is set to 'fr' then velocity should pick fr_email.vm
> and another question how to set this locale/language code in Camel
> springDSL.

Which locale do you refer to. The default locale setting on the JVM?
Or is it somehow a dynamic local set per Camel exchange?

I know Freemarker has built-in support for locales out of the box.
Where it will pick the locale using a naming convention.

Not sure if Veloicty has the same. I suggest to check the velocity docs.

> Please help, i am stuck on this issue, i was not able to find anything in
> camel user guide about this.
> There is something about IRI, but not sure how that works.
> Thanks and Regards.
> Paramjyot
> --
> View this message in context:
> Sent from the Camel - Users mailing list archive at

Claus Ibsen
Red Hat, Inc.
FuseSource is now part of Red Hat
Twitter: davsclaus
Author of Camel in Action:

View raw message