Hi Learn the patterns :)
You need to use the recipient list pattern which can act dynamic. http://camel.apache.org/recipient-list.html On Fri, Nov 19, 2010 at 3:25 PM, yuanchen <[email protected]> wrote: > > I am trying to use ProducerTemplate.sendBodyAndProperty(endpoint, body, > property, propertyValue) or sendBodyAndHeader(endpoint, body, header, > headerValue) to passing some info in the property/header to endpointUri > (used as file name) defined in CamelContext spring config below. How do I > configure the camel context to get the string value from header/property > passed in sendBodyAndHeader/sendBodyAndProperty? > > <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring"> > <route> > <from uri="direct:endpoint"/> > <to uri="file:/?fileName=${some string passed from > property/header}"/> > </route> > </camelContext> > > Thanks a lot for the help, > YC > > -- > View this message in context: > http://camel.465427.n5.nabble.com/How-to-get-header-property-info-out-from-sendBodyAndHeader-sendBodyAndProperty-tp3272364p3272364.html > Sent from the Camel - Users mailing list archive at Nabble.com. > -- Claus Ibsen ----------------- FuseSource Email: [email protected] Web: http://fusesource.com Twitter: davsclaus Blog: http://davsclaus.blogspot.com/ Author of Camel in Action: http://www.manning.com/ibsen/
