To call a remote REST service then CXF can often be overkill.
Sometimes its easier to use plain http or restlet components.

Though it depends, CXF allows to use bean/pojo's and bindings that
makes sense to use if your message body is already a POJO.



On Fri, Nov 20, 2015 at 6:47 PM, Michele
<[email protected]> wrote:
> Hi everyone,
>
> I need to invoke an external rest service and this is my scenario:
>
> 1. From active mq retrieve message
> 2. Invoke external rest service and process response
> 3. On success message is moved to another endpoint.
>
> Using httpapi I obtain a response, but I would like to use httpproxyapi but
> I don't understand how to configure it.
>
> I tried this but doesn't work:
>
> <cxf:rsClient id="rsClient" address="${rs.context path}"
>  serviceClass="com.test.FooService"></cxf:rsClient>
> <camelContext>
>    <route>
>         <from uri="activeness:queue:incoming">
>         <inOut uri="cxfrs:bean:rsClient?httpClientAPI=false">
>        <process ref="ResponseProcessor" />
>      .....
>
> </camelContext>
> Where FooService is an interface.
>
> It seems that interface is not considered.
>
> Where can I found a complete example related to my scenario?
>
> Thanks in advance.
>
> Kind regards.
>
> Michele
>
>
>
>
> --
> View this message in context: 
> http://camel.465427.n5.nabble.com/How-to-invoking-external-rest-service-in-camel-route-tp5774158.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2

Reply via email to