I think what you require is a content filter within the enrich step.
enrich("direct:enrichRoute", fooAggregator);
from("direct:enrichRoute")
.process("bodyFilter") // transforms the current body to what is required for
the request
.to("http://some-api-somewhere");
-----Original Message-----
From: Jon Mithe [mailto:[email protected]]
Sent: 03 September 2014 16:19
To: [email protected]
Subject: pollEnrich using the incomming message excahnge
Hello,
I'm a bit confused / stuck with an enrichment problem.
I have a message that I want to enrich using by making a request to an external
service using part of the information the original message has.
As I unserstand Content Enricher is the EIP I want to use and for camel, the
"enrich" implementation as I want to invoke an external service and use its
reply as a source.
But where I am stuck is when enriching I can't specify what message I want to
send as the enrich request, it seemingly has to be the existing message.
Is there some way of doing a request-reply and formulate a new message /
exhcange for the request part using some information from the old message?
The aggregation would then be the same the old / original message to be
enriched and the reply, the request would be lost.
Thanks,
Jon
--
View this message in context:
http://camel.465427.n5.nabble.com/pollEnrich-using-the-incomming-message-excahnge-tp5756014.html
Sent from the Camel - Users mailing list archive at Nabble.com.