You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Al Ferguson <al...@hotmail.com> on 2013/05/02 21:00:57 UTC

CamelHttpUri and Enricher

Hi, 


Is it possible to override the address of an enricher?

I've tried the following but it does not work. The Enricher still calls the
address of its own uri parameter, and not the one from the CamelHttpUri
header.



Thanks,
Al. F



--
View this message in context: http://camel.465427.n5.nabble.com/CamelHttpUri-and-Enricher-tp5731924.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: CamelHttpUri and Enricher

Posted by Chris Wolf <cw...@gmail.com>.
You didn't paste any of your code....

In any case, here's what I'm doing and it works:

from("direct:readSFTPConfig").routeId("sftp.config")
 .setHeader(Exchange.HTTP_URI, simple("http://
{{ds.host}}:{{ds.port}}/web/rest/client"))
 .setHeader(Exchange.HTTP_QUERY, simple("clientId=${in.header.clientId}"))
 .setHeader(Exchange.HTTP_METHOD, constant("GET"))
  .enrich("http://ignored-set-by-header?throwExceptionOnFailure=false")
[...]

On Fri, May 3, 2013 at 9:35 AM, Al Ferguson <al...@hotmail.com> wrote:

> Hi,
>
> It seems I cannot enrich, what am I doing wrong?
>
> Why is the originalExchange is null?
>
>
> Thanks,
> Al. F
>
>
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/CamelHttpUri-and-Enricher-tp5731924p5731975.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>

Re: CamelHttpUri and Enricher

Posted by Al Ferguson <al...@hotmail.com>.
Hi,

It seems I cannot enrich, what am I doing wrong?

Why is the originalExchange is null?


Thanks,
Al. F



--
View this message in context: http://camel.465427.n5.nabble.com/CamelHttpUri-and-Enricher-tp5731924p5731975.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: CamelHttpUri and Enricher

Posted by Al Ferguson <al...@hotmail.com>.
Works perfectly!  Thanks




--
View this message in context: http://camel.465427.n5.nabble.com/CamelHttpUri-and-Enricher-tp5731924p5731966.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: CamelHttpUri and Enricher

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

You can use recipient list instead
http://camel.apache.org/how-do-i-use-dynamic-uri-in-to.html

It also supports an aggregation strategy to "merge" the result
http://camel.apache.org/recipient-list.html


On Thu, May 2, 2013 at 9:00 PM, Al Ferguson <al...@hotmail.com> wrote:
> Hi,
>
>
> Is it possible to override the address of an enricher?
>
> I've tried the following but it does not work. The Enricher still calls the
> address of its own uri parameter, and not the one from the CamelHttpUri
> header.
>
>
>
> Thanks,
> Al. F
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/CamelHttpUri-and-Enricher-tp5731924.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cibsen@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen