Reputation: 73
I am using a CXF component which will take username and password as its properties and I am getting username and password in Camel Exchange Header, So I tried to set this way:
<to uri="cxf:{myurl}?dataFormat=MESSAGE&username=${in.header.username}&password=${in.header.password}"/>
But it is giving me authentication failure error as username and password are not set properly.
Upvotes: 1
Views: 547
Reputation: 55550
See this FAQ about how to use dynamic values in the to
So by using recipient list EIP you can do this
<recipientList>
<simple>cxf:{myurl}?dataFormat=MESSAGE&username=${in.header.username}&password=${in.header.password}"</simple>
</recipientList>
Upvotes: 1