You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by mitul1411 <mi...@gmail.com> on 2010/08/30 07:03:21 UTC

Calling an external web service in camel route with cxf bc provider

I have an external Axis web service. I want to call it from within a camel
route. The architecture that  I can think of is as follows : 

1. Create a CXF BC Provider endpoint so that Axis can talk to the ESB.
2. Call the Axis service from within a camel route and get its response.
3. Proceed with Camel processing.

But for step 2 , do I need any more configurations. Also , I am unsure as to
how would I call it .
Can anybody help me with it ?

-- 
View this message in context: http://servicemix.396122.n5.nabble.com/Calling-an-external-web-service-in-camel-route-with-cxf-bc-provider-tp2796348p2796348.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Re: Calling an external web service in camel route with cxf bc provider

Posted by mitul1411 <mi...@gmail.com>.
I think , I am still not elaborate on the issue.
It is like , I have to read an id from a properties file ,send it to an
external service which will send me the response. Mean while my XML file is
in a queue. Now , I have to compare the response from the external web
service with the elements of the XML file. But I could not make proper
routing. What would be the best solution ?
-- 
View this message in context: http://servicemix.396122.n5.nabble.com/Calling-an-external-web-service-in-camel-route-with-cxf-bc-provider-tp2796348p2796381.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Re: Calling an external web service in camel route with cxf bc provider

Posted by mitul1411 <mi...@gmail.com>.
The XML file is 

<xmlfile>
 <aa>1</aa>
 <bb>3<//bb>
 <cc>2</cc>
</xmlfile>
-- 
View this message in context: http://servicemix.396122.n5.nabble.com/Calling-an-external-web-service-in-camel-route-with-cxf-bc-provider-tp2796348p2796362.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Re: Calling an external web service in camel route with cxf bc provider

Posted by mitul1411 <mi...@gmail.com>.
I already have the XML file in the queue. I want to compare the response
values from the  web service with the XML file using XPath. I do not want to
transform it.


Lets say , the XML file is :

<xmlfile>
   1 
  3
  <c>2</c>
</xmlfile>

Now ,I  want to  compare the value a=1 , b=2, c=3  coming from the web
service with this.

If they are matching send them to location "x" else send them to location
"y". Similar to Content Based Routing.




-- 
View this message in context: http://servicemix.396122.n5.nabble.com/Calling-an-external-web-service-in-camel-route-with-cxf-bc-provider-tp2796348p2796361.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Re: Calling an external web service in camel route with cxf bc provider

Posted by Freeman Fang <fr...@gmail.com>.
Then how about use camel-saxon endpoint[1]?
[1]http://camel.apache.org/xquery-endpoint.html

Freeman
On 2010-8-30, at 下午1:23, mitul1411 wrote:

>
> Thanks for the link. I think I have not described my problem in  
> depth. Sorry
> for that.
>
> The scenario is :
>
> If I get the values a=1,b=2,c=3 as response from the external web  
> service
> that is called , I want to use those values with the XPath. How can  
> I use it
> ?
> -- 
> View this message in context: http://servicemix.396122.n5.nabble.com/Calling-an-external-web-service-in-camel-route-with-cxf-bc-provider-tp2796348p2796359.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.


-- 
Freeman Fang

------------------------
blog: http://freemanfang.blogspot.com
twitter: http://twitter.com/freemanfang
Open Source SOA: http://fusesource.com
Apache Servicemix:http://servicemix.apache.org
Apache Cxf: http://cxf.apache.org
Apache Karaf: http://karaf.apache.org
Apache Felix: http://felix.apache.org


Re: Calling an external web service in camel route with cxf bc provider

Posted by mitul1411 <mi...@gmail.com>.
Thanks for the link. I think I have not described my problem in depth. Sorry
for that.

The scenario is :

If I get the values a=1,b=2,c=3 as response from the external web service
that is called , I want to use those values with the XPath. How can I use it
?
-- 
View this message in context: http://servicemix.396122.n5.nabble.com/Calling-an-external-web-service-in-camel-route-with-cxf-bc-provider-tp2796348p2796359.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Re: Calling an external web service in camel route with cxf bc provider

Posted by Freeman Fang <fr...@gmail.com>.
Hi,

Here cxf bc provider is a jbi endpoint, about how camel router call  
jbi endpoint, take a look at [1]

[1]http://camel.apache.org/jbi.html

Freeman
On 2010-8-30, at 下午1:03, mitul1411 wrote:

>
> I have an external Axis web service. I want to call it from within a  
> camel
> route. The architecture that  I can think of is as follows :
>
> 1. Create a CXF BC Provider endpoint so that Axis can talk to the ESB.
> 2. Call the Axis service from within a camel route and get its  
> response.
> 3. Proceed with Camel processing.
>
> But for step 2 , do I need any more configurations. Also , I am  
> unsure as to
> how would I call it .
> Can anybody help me with it ?
>
> -- 
> View this message in context: http://servicemix.396122.n5.nabble.com/Calling-an-external-web-service-in-camel-route-with-cxf-bc-provider-tp2796348p2796348.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.


-- 
Freeman Fang

------------------------
blog: http://freemanfang.blogspot.com
twitter: http://twitter.com/freemanfang
Open Source SOA: http://fusesource.com
Apache Servicemix:http://servicemix.apache.org
Apache Cxf: http://cxf.apache.org
Apache Karaf: http://karaf.apache.org
Apache Felix: http://felix.apache.org