syncope-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Colm O hEigeartaigh <cohei...@apache.org>
Subject Re: Referencing user attributes in Camel routes
Date Mon, 11 Jul 2016 17:05:13 GMT
I'm going to answer my own question here in case anyone else runs into it.
The UserTO Object is stored as a "actual" property on the Camel exchange in
the createUser route...you can access it then in the route via:

<setHeader headerName="subject"><simple>Hello
${exchangeProperty.actual.username}</simple></setHeader>

Colm.

On Mon, Jul 11, 2016 at 5:36 PM, Colm O hEigeartaigh <coheigea@apache.org>
wrote:

> Hi,
>
> I assume it's possible to reference user attributes in Camel routes
> somehow, but I could manage to get it working from an initial try. So as an
> example, let's say we're using the Camel mail component to send a mail on a
> new user creation, and we want to set the Subject Header to include the
> user attribute "username" - how is it possible to reference the username?
>
> I had thought something like the following should work, but it doesn't:
>
> <setHeader headerName="subject"><simple>New user created:
> ${body.username}</simple></setHeader>
>
> Thanks,
>
> Colm.
>
>
> --
> Colm O hEigeartaigh
>
> Talend Community Coder
> http://coders.talend.com
>



-- 
Colm O hEigeartaigh

Talend Community Coder
http://coders.talend.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message