camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christian Schneider <ch...@die-schneider.net>
Subject Request reply with endpoint resolved from expression
Date Sun, 11 Mar 2012 18:56:41 GMT
Hi all,

I wanted to call an endpoint that was specified using an expression. 
This is a case that I typically solved using the
recipientList(Expr) dsl item. The problem was that in this case the 
endpoint was request/reply. Using recipientList I was not able to work 
with the reply from the endpoint.

I solved this using a bean that was given the expr in the constructor 
and that used:
String epSt = expr.evaluate(exchange);
Endpoint ep = exchange.getContext().getEndpoint(epSt);
ep.process(exchange);

This works but I wonder if we should build this behaviour into camel. Or 
is this already possible?

Christian

-- 

Christian Schneider
http://www.liquid-reality.de

Open Source Architect
Talend Application Integration Division http://www.talend.com


Mime
View raw message