yes, it works

                                        <setHeader headerName="req-project">
                                                
<simple>${in.headers.req-project}</simple>
                                        </setHeader>
                                        <setHeader headerName="req-id">
                                                
<simple>${in.headers.req-id}</simple>
                                        </setHeader>


where ${in.headers.req-project} is not a header but a property

Thanks
Matteo


RomKal wrote:
> 
> 2009/5/6 Matteo Redaelli <matteo.redae...@libero.it>:
>>
>> Thanks Claus for you answer, I'll look at the XSD for any future issue.
>>
>> But sorry for the silly question: now that I can set a property, how can
>> I
>> retrieve it in spring xml?
>> do I have to set a header with the value of my new property to use it in
>> a
>> velocity template?
> 
> I believe velocity will see it the same way as headers. But I'm not sure.
> 
> You can of course also set it as header just before velocity endpoint
> and there is... strange convention that whenever you read your header
> via header() or <header> it reads the header, but if none exists, it
> returns the propoerty. So to set a header 'foo' to the value of 'foo'
> property you do
> 
> setHeader("foo", header("foo"))
> 
> looks strange, but works :D
> 
> Roman
> 
> 

-- 
View this message in context: 
http://www.nabble.com/How-long-do-the-camel-headers-live-in-routes--tp23375104p23428651.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to