I'm using the oxf:delegation processor to successfully make rpc SOAP calls.
However, the resulting data output from the delegation processor only seems to contain the <response> part of the SOAP envelope. I have cases where the <response> identifies hrefs to pick up data from the rest of the SOAP envelope, eg <response> <item href="#id0"/> <item href="#id1"/> </response> How do I get this data, which should be in part of the SOAP envelope identified something like <multiref id="id0" ...>some data</multiref> <multiref id="id1" ...> some more data</multiref> Steve -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
Answered my own question... For anyone who's interested:
Include a select attribute on the operation element in the oxf:delegation processor Set the value of the select attribute to be "/" to return the complete SOAP envelope (or any other XPATH expression depending what you want to be returned). In my case this now means parsing the <response> part to pick up the href IDs, and then getting the other parts of the document based on these. Steve -----Original Message----- From: Stephen Bayliss Sent: 05 September 2005 15:07 To: [hidden email] Subject: [ops-users] SOAP multi-part responses I'm using the oxf:delegation processor to successfully make rpc SOAP calls. However, the resulting data output from the delegation processor only seems to contain the <response> part of the SOAP envelope. I have cases where the <response> identifies hrefs to pick up data from the rest of the SOAP envelope, eg <response> <item href="#id0"/> <item href="#id1"/> </response> How do I get this data, which should be in part of the SOAP envelope identified something like <multiref id="id0" ...>some data</multiref> <multiref id="id1" ...> some more data</multiref> Steve -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
Steve,
I've just encountered the same multiRef issue. The web services I'm working on responds with the following pattern: <soap:body> <response> <item href="x"/> <item href="xx"/> </response> <multiRef id="x"/> <multiRef id="xx"/> </soap:body> By default (when operation/@select not specified), OPS delegation returns everything after <soap:body> which in this case not a well- formed XML. I didn't get any response at all, except the 'could not be added to the branch "null" ' error message. So thank you for this tips. I think the use of the "select" attribute should be shown in the code example in the documentation. Regards, Boon ----- Boon Low System Development Officer, EGEE Training and Induction UK National e-Science Centre http://homepages.ed.ac.uk/boon On 5 Sep 2005, at 15:35, Stephen Bayliss wrote: > Answered my own question... For anyone who's interested: > > Include a select attribute on the operation element in the > oxf:delegation processor > Set the value of the select attribute to be "/" to return the complete > SOAP envelope (or any other XPATH expression depending what you > want to > be returned). > > In my case this now means parsing the <response> part to pick up the > href IDs, and then getting the other parts of the document based on > these. > > Steve > > > -----Original Message----- > From: Stephen Bayliss > Sent: 05 September 2005 15:07 > To: [hidden email] > Subject: [ops-users] SOAP multi-part responses > > I'm using the oxf:delegation processor to successfully make rpc SOAP > calls. > > However, the resulting data output from the delegation processor only > seems to contain the <response> part of the SOAP envelope. > > I have cases where the <response> identifies hrefs to pick up data > from > the rest of the SOAP envelope, eg > <response> > <item href="#id0"/> > <item href="#id1"/> > </response> > > How do I get this data, which should be in part of the SOAP envelope > identified something like > <multiref id="id0" ...>some data</multiref> > <multiref id="id1" ...> some more data</multiref> > > Steve > > > > > -- > You receive this message as a subscriber of the ops- > [hidden email] mailing list. > To unsubscribe: mailto:[hidden email] > For general help: mailto:[hidden email]?subject=help > ObjectWeb mailing lists service home page: http://www.objectweb.org/ > wws > -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
In reply to this post by Stephen Bayliss
Boon
That's exactly the pattern that my web service is responding with for one of the calls; wonder if we are using the same one? I found the most flexible approach was to select the whole of the SOAP envelope, and have some XSLT post-processing in my pipeline to return the parts I need depending on the call that I'm making; controlling the whole lot with an XML API configuration file. Steve -----Original Message----- From: Boon Low [mailto:[hidden email]] Sent: 08 September 2005 16:48 To: [hidden email] Subject: Re: [ops-users] SOAP multi-part responses Steve, I've just encountered the same multiRef issue. The web services I'm working on responds with the following pattern: <soap:body> <response> <item href="x"/> <item href="xx"/> </response> <multiRef id="x"/> <multiRef id="xx"/> </soap:body> By default (when operation/@select not specified), OPS delegation returns everything after <soap:body> which in this case not a well- formed XML. I didn't get any response at all, except the 'could not be added to the branch "null" ' error message. So thank you for this tips. I think the use of the "select" attribute should be shown in the code example in the documentation. Regards, Boon ----- Boon Low System Development Officer, EGEE Training and Induction UK National e-Science Centre http://homepages.ed.ac.uk/boon On 5 Sep 2005, at 15:35, Stephen Bayliss wrote: > Answered my own question... For anyone who's interested: > > Include a select attribute on the operation element in the > oxf:delegation processor > Set the value of the select attribute to be "/" to return the complete > SOAP envelope (or any other XPATH expression depending what you > want to > be returned). > > In my case this now means parsing the <response> part to pick up the > href IDs, and then getting the other parts of the document based on > these. > > Steve > > > -----Original Message----- > From: Stephen Bayliss > Sent: 05 September 2005 15:07 > To: [hidden email] > Subject: [ops-users] SOAP multi-part responses > > I'm using the oxf:delegation processor to successfully make rpc SOAP > calls. > > However, the resulting data output from the delegation processor only > seems to contain the <response> part of the SOAP envelope. > > I have cases where the <response> identifies hrefs to pick up data > from > the rest of the SOAP envelope, eg > <response> > <item href="#id0"/> > <item href="#id1"/> > </response> > > How do I get this data, which should be in part of the SOAP envelope > identified something like > <multiref id="id0" ...>some data</multiref> > <multiref id="id1" ...> some more data</multiref> > > Steve > > > > > -- > You receive this message as a subscriber of the ops- > [hidden email] mailing list. > To unsubscribe: mailto:[hidden email] > For general help: mailto:[hidden email]?subject=help > ObjectWeb mailing lists service home page: http://www.objectweb.org/ > wws > -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
Administrator
|
In reply to this post by Boon Low
Boon Low wrote:
> Steve, > > I've just encountered the same multiRef issue. The web services I'm > working on responds with the following pattern: > > <soap:body> > <response> > <item href="x"/> > <item href="xx"/> > </response> > <multiRef id="x"/> > <multiRef id="xx"/> > </soap:body> > > By default (when operation/@select not specified), OPS delegation > returns everything after <soap:body> which in this case not a well- > formed XML. I didn't get any response at all, except the 'could not be > added to the branch "null" ' error message. > > So thank you for this tips. I think the use of the "select" attribute > should be shown in the code example in the documentation. not shown in the XML snippets, it is in fact documented. See: http://www.orbeon.com/ops/doc/processors-delegation "Optionally you can declare what part of the SOAP result document is returned by specifying an XPath expression in the optional select attribute on the operation element. If you don't specify an expression, by default when the style is RPC the content of the first child element under the SOAP body is returned, and when the style is document the content of the SOAP body is returned." -Erik -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
In reply to this post by Stephen Bayliss
Hi,
I am new to Axis2\c. I am trying to get the multiref values from the response. But I am not able to do so. I tried "select" attribute option but not able to get the full Envelop response. If anybody has used this attributes, please let me know. I used TCPMon to check the packets. I found that the <soapenv:Body> contains operation response and also multiref values. Please help me to know, how to access the multiRef values. Thanks, Vishal -- This message was sent on behalf of [hidden email] at openSubscriber.com http://www.opensubscriber.com/message/ops-users@.../2123358.html -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Hi Vishal
I've previously processed SOAP multi-part responses by setting the select attribute to "/", and using some xslt to process the resulting response. I'd recommend soapUI http://www.soapui.org/ as an excellent tool for debugging - you can see the request and response using this tool, and once you can see the XML response you'll probably have a better idea for how to process it. I believe the select attribute will work fine, you'll just need the correct xpath to get the part of the envelope you want, but be careful to specify namespaces for any namespace prefixes that you use. Regards Steve -----Original Message----- From: [hidden email] [mailto:[hidden email]] Sent: 25 March 2008 11:24 To: [hidden email] Subject: [ops-users] Re: RE: SOAP multi-part responses Hi, I am new to Axis2\c. I am trying to get the multiref values from the response. But I am not able to do so. I tried "select" attribute option but not able to get the full Envelop response. If anybody has used this attributes, please let me know. I used TCPMon to check the packets. I found that the <soapenv:Body> contains operation response and also multiref values. Please help me to know, how to access the multiRef values. Thanks, Vishal -- This message was sent on behalf of [hidden email] at openSubscriber.com http://www.opensubscriber.com/message/ops-users@.../2123358.html -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
In reply to this post by vishal_khutale
H Vishal, I used the select attribute to open and discard, as it were, the envelope, and deliver a document with just the multiref elements: select="//multiRef" the whole step: <p:processor name="oxf:delegation"> <p:input name="interface"> <config> <service id="StandardService" type="webservice" endpoint="http://www.nacse.org/neesSiteSpecs/ services/StandardService"> <operation nsuri="http://service.ssdb.nacse.org" name="getEquipmentByID" encodingStyle="http://schemas.xmlsoap.org/ soap/encoding/" select="//multiRef"/> <!-- Select / when testing --> </service> </config> </p:input> <p:input name="data"><dummy/></p:input> <p:input name="call" href="#call-1"/> <p:output name="data" id="ssdb-1"/> </p:processor> Cheers, Hank On Mar 25, 2008, at 4:23 AM, [hidden email] wrote: > Hi, > > I am new to Axis2\c. > > I am trying to get the multiref values from the response. But I am > not able to do so. I tried "select" attribute option but not able > to get the full Envelop response. If anybody has used this > attributes, please let me know. > > I used TCPMon to check the packets. I found that the <soapenv:Body> > contains operation response and also multiref values. > > Please help me to know, how to access the multiRef values. > > Thanks, > Vishal > > -- > This message was sent on behalf of [hidden email] at > openSubscriber.com > http://www.opensubscriber.com/message/ops-users@.../ > 2123358.html > > -- > You receive this message as a subscriber of the [hidden email] > mailing list. > To unsubscribe: mailto:[hidden email] > For general help: mailto:[hidden email]?subject=help > OW2 mailing lists service home page: http://www.ow2.org/wws NEES@UCSB Institute for Crustal Studies, University of California, Santa Barbara 805-893-8042 -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
In reply to this post by vishal_khutale
Hi Vishal
I've previously processed SOAP multi-part responses by setting the select attribute to "/", and using some xslt to process the resulting response. I'd recommend soapUI http://www.soapui.org/ as an excellent tool for debugging - you can see the request and response using this tool, and once you can see the XML response you'll probably have a better idea for how to process it. I believe the select attribute will work fine, you'll just need the correct xpath to get the part of the envelope you want, but be careful to specify namespaces for any namespace prefixes that you use. Regards Steve -----Original Message----- From: [hidden email] [mailto:[hidden email]] Sent: 25 March 2008 11:24 To: [hidden email] Subject: [ops-users] Re: RE: SOAP multi-part responses Hi, I am new to Axis2\c. I am trying to get the multiref values from the response. But I am not able to do so. I tried "select" attribute option but not able to get the full Envelop response. If anybody has used this attributes, please let me know. I used TCPMon to check the packets. I found that the <soapenv:Body> contains operation response and also multiref values. Please help me to know, how to access the multiRef values. Thanks, Vishal -- This message was sent on behalf of [hidden email] at openSubscriber.com http://www.opensubscriber.com/message/ops-users@.../2123358.html -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Free forum by Nabble | Edit this page |