Author |
Message
|
Ranpie49 |
Posted: Wed Apr 22, 2015 4:27 am Post subject: SOAP Request - Compute node |
|
|
Newbie
Joined: 22 Apr 2015 Posts: 5
|
Hello everything,
I try to create a soap request with a compute node before using a soap request node. But I don't manage to know if my code esql has an error :
Code: |
<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:impl="http://blabla.blabla.fr">
<soapenv:Header/>
<soapenv:Body>
<impl:function soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<data xsi:type="x-:Map" xmlns:x-="http://xml.apache.org/xml-soap">
NULL
</data>
</impl:function>
</soapenv:Body>
</soapenv:Envelope> |
Code: |
DECLARE xsi NAMESPACE 'http://www.w3.org/2001/XMLSchema-instance';
DECLARE xsd NAMESPACE 'http://www.w3.org/2001/XMLSchema';
DECLARE impl NAMESPACE 'http://blabla.blabla.fr';
DECLARE soapenv NAMESPACE 'http://schemas.xmlsoap.org/soap/envelope/';
CALL CopyMessageHeaders();
SET OutputRoot.Properties.MessageType = 'Envelope';
SET OutputRoot.Properties.IdentityMappedType = 'usernameAndPassword';
SET OutputRoot.Properties.IdentitySourceToken = '********';
SET OutputRoot.Properties.IdentitySourcePassword = '*******';
SET OutputRoot.XMLNSC.soapenv:Envelope.soapenv:Body.impl:function.xsi:data = 'NULL'; |
How can I add attribute in the <impl:function> node and <data> node |
|
Back to top |
|
 |
smdavies99 |
Posted: Wed Apr 22, 2015 5:17 am Post subject: |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
Wrong thread sorry. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
Ranpie49 |
Posted: Wed Apr 22, 2015 5:21 am Post subject: |
|
|
Newbie
Joined: 22 Apr 2015 Posts: 5
|
Hello smdavies99
Could you tell me more pls ?  |
|
Back to top |
|
 |
MQEnthu |
Posted: Wed Apr 22, 2015 5:58 am Post subject: |
|
|
 Partisan
Joined: 06 Oct 2008 Posts: 329 Location: India
|
Is the soap msg you posted output of your code?
And what is the issue? _________________ -----------------------------------------------
It is good to remember the past,
but don't let past capture your future |
|
Back to top |
|
 |
Ranpie49 |
Posted: Wed Apr 22, 2015 6:13 am Post subject: |
|
|
Newbie
Joined: 22 Apr 2015 Posts: 5
|
The SOAP message I'v posted, is the message I suppose to send before the SOAP request node.
My message flow is the following :
HTTP Input --> Comput --> SOAP Request --> SOAP Extract --> HTTP Reply
I call the service with the URL of the HTTP Input node.
The issue is a SOAP Message with an error, but I don't know it's linked with what I've done in the compute node.
But I wish I had your opinion about my esql code. |
|
Back to top |
|
 |
mqjeff |
Posted: Wed Apr 22, 2015 6:16 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Ranpie49 wrote: |
The issue is a SOAP Message with an error |
troubleshoot this
Ranpie49 wrote: |
But I wish I had your opinion about my esql code. |
It looks like ESQL code. |
|
Back to top |
|
 |
Ranpie49 |
Posted: Wed Apr 22, 2015 6:51 am Post subject: |
|
|
Newbie
Joined: 22 Apr 2015 Posts: 5
|
Thanks mqjeff. I was not sure if it was ESQL code..
My error :
Quote: |
First Element must contain the local name, Envelope , but found html |
I think it's probably due to an error 404 or 500, but how can I know more about it ? |
|
Back to top |
|
 |
mqjeff |
Posted: Wed Apr 22, 2015 7:04 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Ranpie49 wrote: |
Quote: |
First Element must contain the local name, Envelope , but found html |
|
Where would that be coming from? |
|
Back to top |
|
 |
Ranpie49 |
Posted: Wed Apr 22, 2015 7:13 am Post subject: |
|
|
Newbie
Joined: 22 Apr 2015 Posts: 5
|
I test my service with SOAP UI. |
|
Back to top |
|
 |
mqjeff |
Posted: Wed Apr 22, 2015 7:15 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Ranpie49 wrote: |
I test my service with SOAP UI. |
It doesn't matter what you use to test it. |
|
Back to top |
|
 |
iibmate |
Posted: Thu Apr 23, 2015 11:32 pm Post subject: Re: SOAP Request - Compute node |
|
|
 Apprentice
Joined: 17 Mar 2015 Posts: 38 Location: Perth, WA
|
For this soap request :
Ranpie49 wrote: |
Code: |
<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:impl="http://blabla.blabla.fr">
<soapenv:Header/>
<soapenv:Body>
<impl:function soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<data xsi:type="x-:Map" xmlns:x-="http://xml.apache.org/xml-soap">
NULL
</data>
</impl:function>
</soapenv:Body>
</soapenv:Envelope> |
|
This code
Quote: |
Code: |
DECLARE xsi NAMESPACE 'http://www.w3.org/2001/XMLSchema-instance';
DECLARE xsd NAMESPACE 'http://www.w3.org/2001/XMLSchema';
DECLARE impl NAMESPACE 'http://blabla.blabla.fr';
DECLARE soapenv NAMESPACE 'http://schemas.xmlsoap.org/soap/envelope/';
CALL CopyMessageHeaders();
SET OutputRoot.Properties.MessageType = 'Envelope';
SET OutputRoot.Properties.IdentityMappedType = 'usernameAndPassword';
SET OutputRoot.Properties.IdentitySourceToken = '********';
SET OutputRoot.Properties.IdentitySourcePassword = '*******';
SET OutputRoot.XMLNSC.soapenv:Envelope.soapenv:Body.impl:function.xsi:data = 'NULL'; |
|
is not enough.
Quote: |
How can I add attribute in the <impl:function> node and <data> node
|
Try searching information center for keyword "Manipulating messages in XMLNSC domain" |
|
Back to top |
|
 |
fjb_saper |
Posted: Fri Apr 24, 2015 4:40 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
That last part
Quote: |
Code: |
SET OutputRoot.XMLNSC.soapenv:Envelope.soapenv:Body.impl:function.xsi:data = 'NULL'; |
|
should most likely be:
Code: |
SET OutputRoot.XMLNSC.soapenv:Envelope.soapenv:Body.impl:function.data.(XMLNSC.ATTRIBUTE)xsi:type='x-:Map';
........ data.(XMLNSC.NameSpaceDecl)xmlns:"x-"='http://......';
SET OutputRoot.XMLNSC.soapenv:Envelope.soapenv:Body.impl:function.data VALUE = 'NULL';
|
And don't forget to declare "x-" as an ESQL namespace variable...
Have fun  _________________ MQ & Broker admin
Last edited by fjb_saper on Fri Apr 24, 2015 10:11 am; edited 1 time in total |
|
Back to top |
|
 |
mqjeff |
Posted: Fri Apr 24, 2015 5:26 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
I don't see any code that will remove the source of the html tag. |
|
Back to top |
|
 |
fjb_saper |
Posted: Fri Apr 24, 2015 7:30 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
mqjeff wrote: |
I don't see any code that will remove the source of the html tag. |
Sure, but
Quote: |
Code: |
Call CopyMessageHeaders(); |
|
should have gotten rid of anything lingering in the body... assuming that he did not have anything copying other stuff before those lines... Also the return html might have been a consequence of a poorly formatted request, or a request with incorrect data....  _________________ MQ & Broker admin |
|
Back to top |
|
 |
trinath |
Posted: Fri Apr 24, 2015 9:59 am Post subject: |
|
|
 Apprentice
Joined: 02 Jun 2014 Posts: 34
|
Hi Ranpie49,
Just try this code
Code: |
SET OutputRoot.XMLNSC.soapenv:Envelope.soapenv:Body.(XMLNSC.Attribute)"impl:function soapenv:encodingStyle"='http://schemas.xmlsoap.org/soap/encoding/'; |
|
|
Back to top |
|
 |
|