mmenti
06-28-2005, 04:59 AM
Hi,
I've found something that caused me a problem when attempting to integrate Laszlo with a web service: for some reason the Laszlo soap client seems to create a <multiRef> for data of type short, which causes the web service to return a SOAP Invalid Request error.
This is from the WSDL:
<message name="PostInterviewEventIn">
<part name="InterviewSessionToken" type="s:string"/>
<part name="ForceRestart" type="s:short"/>
<part name="PlayerXML" type="s:string"/>
</message>
When using a protocol sniffer, I can see that this is what is sent from the Laszlo application:
<soapenv:Envelope·xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"·xmlns:xsd="http://www.w3.org/2001/XMLSchema"·xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<ns1:PostInterviewEvent·soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"·xmlns:ns1="urn:mrIEngWS">
<InterviewSessionToken·xsi:type="xsd:string">6n234n2f2wrejlf3tl4x2iv4le5bmaqa</InterviewSessionToken>
<ForceRestart·href="#id0"/>
<PlayerXML·xsi:type="xsd:string"><Page·SavePoint="single"><Question·QuestionName="s ingle"><Response><Value>{Yes}</Value></Response></Question><Navigation·Type="Next"·IsSelected="true"/></Page></PlayerXML>
</ns1:PostInterviewEvent>
<multiRef·id="id0"·soapenc:root="0"·soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"·xsi:type="xsd:short"·xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">1</multiRef>
</soapenv:Body>
</soapenv:Envelope>
If I do the same call in Perl (using SOAP::Lite), it sends this:
<?xml·version="1.0"·encoding="UTF-8"?>
<SOAP-ENV:Envelope·xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"·xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"·xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"·xmlns:xsd="http://www.w3.org/1999/XMLSchema"·SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Body>
<namesp7:PostInterviewEvent·xmlns:namesp7="urn:mrIEngWS">
<InterviewSessionToken·xsi:type="ns:string"·xmlns:ns="http://www.w3.org/2001/XMLSchema">vm2imiguzp4ulorzaurdink4qu2bmaqa</InterviewSessionToken>
<ForceRestart·xsi:type="ns:short"·xmlns:ns="http://www.w3.org/2001/XMLSchema">1</ForceRestart>
<PlayerXML·xsi:type="ns:string"·xmlns:ns="http://www.w3.org/2001/XMLSchema"><Page·SavePoint="single"><Question·QuestionName="single"><Response><Value>{Yes}</Value></Response></Question><Navigation·Type="Next"·IsSelected="true"/></Page></PlayerXML>
</namesp7:PostInterviewEvent>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
You can see that SOAP::Lite hasn't created the <multiRef>, and works with the web service, while the Laszlo client generates the <multiRef>, which appears to cause a SOAP error with the web service.
I can (sort of) work around this by editing the wsdl and change s:short to s:string, but was wondering if anyone knew what was going on here?
Many thanks for your help,
Mario.
I've found something that caused me a problem when attempting to integrate Laszlo with a web service: for some reason the Laszlo soap client seems to create a <multiRef> for data of type short, which causes the web service to return a SOAP Invalid Request error.
This is from the WSDL:
<message name="PostInterviewEventIn">
<part name="InterviewSessionToken" type="s:string"/>
<part name="ForceRestart" type="s:short"/>
<part name="PlayerXML" type="s:string"/>
</message>
When using a protocol sniffer, I can see that this is what is sent from the Laszlo application:
<soapenv:Envelope·xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"·xmlns:xsd="http://www.w3.org/2001/XMLSchema"·xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<ns1:PostInterviewEvent·soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"·xmlns:ns1="urn:mrIEngWS">
<InterviewSessionToken·xsi:type="xsd:string">6n234n2f2wrejlf3tl4x2iv4le5bmaqa</InterviewSessionToken>
<ForceRestart·href="#id0"/>
<PlayerXML·xsi:type="xsd:string"><Page·SavePoint="single"><Question·QuestionName="s ingle"><Response><Value>{Yes}</Value></Response></Question><Navigation·Type="Next"·IsSelected="true"/></Page></PlayerXML>
</ns1:PostInterviewEvent>
<multiRef·id="id0"·soapenc:root="0"·soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"·xsi:type="xsd:short"·xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">1</multiRef>
</soapenv:Body>
</soapenv:Envelope>
If I do the same call in Perl (using SOAP::Lite), it sends this:
<?xml·version="1.0"·encoding="UTF-8"?>
<SOAP-ENV:Envelope·xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"·xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"·xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"·xmlns:xsd="http://www.w3.org/1999/XMLSchema"·SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Body>
<namesp7:PostInterviewEvent·xmlns:namesp7="urn:mrIEngWS">
<InterviewSessionToken·xsi:type="ns:string"·xmlns:ns="http://www.w3.org/2001/XMLSchema">vm2imiguzp4ulorzaurdink4qu2bmaqa</InterviewSessionToken>
<ForceRestart·xsi:type="ns:short"·xmlns:ns="http://www.w3.org/2001/XMLSchema">1</ForceRestart>
<PlayerXML·xsi:type="ns:string"·xmlns:ns="http://www.w3.org/2001/XMLSchema"><Page·SavePoint="single"><Question·QuestionName="single"><Response><Value>{Yes}</Value></Response></Question><Navigation·Type="Next"·IsSelected="true"/></Page></PlayerXML>
</namesp7:PostInterviewEvent>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
You can see that SOAP::Lite hasn't created the <multiRef>, and works with the web service, while the Laszlo client generates the <multiRef>, which appears to cause a SOAP error with the web service.
I can (sort of) work around this by editing the wsdl and change s:short to s:string, but was wondering if anyone knew what was going on here?
Many thanks for your help,
Mario.