in reply to Re^2: SOAP::Lite, but not the problem?
in thread SOAP::Lite, but not the problem?
Let's have a look at the two requests as per the trace you posted:
<?xml version="1.0" encoding="UTF-8"?> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsdlns="http://tempuri.org/wsdl/" xmlns:stk="http://schemas.microsoft.com/soap-toolkit/wsdl-extensio +n" soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:typens="http://tempuri.org/type" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:namesp1="http://tempuri.org/message/"> <soap:Body> <namesp1:TransactionProcess> <inputTrans xsi:type="xsd:string"> <transaction> <merchant_id>XXXXXXXXXXXXX</merchant_id> <trnType>PA</trnType> <trnCardOwner>myname</trnCardOwner> <trnCardNumber>4030000010001234</trnCardNumber> <trnExpMonth>01</trnExpMonth> <trnExpYear>09</trnExpYear> <trnAmount>1.00</trnAmount> <trnCardCvd>123</trnCardCvd> <ordEmailAddress>sdfgf@glbcom.net</ordEmailAddress> <ordName>LFirstName LLastName</ordName> <ordPhoneNumber>6048745874</ordPhoneNumber> <ordAddress1>my addr</ordAddress1> <ordAddress2></ordAddress2> <ordCity>city</ordCity> <ordProvince>MB</ordProvince> <ordPostalCode>90210</ordPostalCode> <ordCountry>CA</ordCountry> <trnCurrency>USD</trnCurrency> </transaction> </inputTrans> </namesp1:TransactionProcess> </soap:Body> </soap:Envelope>
<?xml version="1.0" encoding="UTF-8"?> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdlns="http://tempuri.org/wsdl/" xmlns:stk="http://schemas.microsoft.com/soap-toolkit/wsdl-extensio +n" soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:typens="http://tempuri.org/type" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:namesp1="http://tempuri.org/message/"> <soap:Body> <namesp1:TransactionProcess> <inputTrans xsi:type="xsd:string"> <transaction> <merchant_id>XXXXXXXXXXXXX</merchant_id> <trnType>PA</trnType> <trnCardOwner>myname</trnCardOwner> <trnCardNumber>4030000010001234</trnCardNumber> <trnExpMonth>01</trnExpMonth> <trnExpYear>09</trnExpYear> <trnAmount>1.00</trnAmount> <trnCardCvd>123</trnCardCvd> <ordEmailAddress>sdfgf@glbcom.net</ordEmailAddress> <ordName>LFirstName LLastName</ordName> <ordPhoneNumber>6048745874</ordPhoneNumber> <ordAddress1>my addr</ordAddress1> <ordAddress2></ordAddress2> <ordCity>city</ordCity> <ordProvince>MB</ordProvince> <ordPostalCode>90210</ordPostalCode> <ordCountry>CA</ordCountry> <trnCurrency>USD</trnCurrency> </transaction> </inputTrans> </namesp1:TransactionProcess> </soap:Body> </soap:Envelope>
The differing lines are:bollock@localhost [~] diff -u redhat_request.xml debian_request.xml --- redhat_request.xml 2007-11-14 12:39:48.000000000 +1000 +++ debian_request.xml 2007-11-14 12:48:27.000000000 +1000 @@ -1,13 +1,13 @@ <?xml version="1.0" encoding="UTF-8"?> <soap:Envelope - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" - xmlns:wsdlns="http://tempuri.org/wsdl/" - xmlns:stk="http://schemas.microsoft.com/soap-toolkit/wsdl-extensi +on" - soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" - xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" - xmlns:typens="http://tempuri.org/type" - xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:wsdlns="http://tempuri.org/wsdl/" + xmlns:stk="http://schemas.microsoft.com/soap-toolkit/wsdl-extensi +on" + soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" + xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" + xmlns:typens="http://tempuri.org/type" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:namesp1="http://tempuri.org/message/"> <soap:Body> <namesp1:TransactionProcess>
So your two installations are sending differing 'soap' namespace values. Let's look at the SOAPFault you received back from the server for the debian request:- xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
<?xml version="1.0" encoding="utf-8"?> <SOAP-ENV:Envelope xmlns:SOAPSDK1="http://www.w3.org/2001/XMLSchema" xmlns:SOAPSDK2="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAPSDK3="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP-ENV:Body SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/so +ap/encoding/"> <SOAP-ENV:Fault> <faultcode>SOAP-ENV:VersionMismatch</faultcode> <faultstring> VersionMismatch:The Soap processor found an invalid namespace +for the SOAP Envelope element. </faultstring> <detail> <mserror:errorInfo xmlns:mserror="http://schemas.microsoft.com +/soap-toolk it/faultdetail/error/"> <mserror:returnCode /> <mserror:serverErrorInfo> <mserror:description> VersionMismatch:The Soap processor found an invalid name +space for the SOAP Envelope element. HRESULT=0x800A1BBD - Server:An unanticipated error occur +red during the processing of this request. HRESULT=0x800A1BBD </mserror:description> <mserror:source>VersionMismatch</mserror:source> </mserror:serverErrorInfo> <mserror:callStack> <mserror:callElement> <mserror:component>VersionMismatch</mserror:component> <mserror:description> The Soap processor found an invalid namespace for the +SOAP Envelope element. </mserror:description> <mserror:returnCode /> </mserror:callElement> <mserror:callElement> <mserror:component>Server</mserror:component> <mserror:description> An unanticipated error occurred during the processing +of this request. </mserror:description> <mserror:returnCode /> </mserror:callElement> </mserror:callStack> </mserror:errorInfo> </detail> </SOAP-ENV:Fault> </SOAP-ENV:Body> </SOAP-ENV:Envelope>
I've reformatted the opening section of the WSDL you posted:
<?xml version="1.0" encoding="utf-8"?> <definitions xmlns:wsdlns="http://tempuri.org/wsdl/" xmlns:typens="http://tempuri.org/type" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:stk="http://schemas.microsoft.com/soap-toolkit/wsdl-extensio +n" xmlns="http://schemas.xmlsoap.org/wsdl/" name="ProcessTransaction" targetNamespace="http://tempuri.org/wsdl/"> <types>
At first I thought that perhaps the web-service was serving different versions of the WSDL document, and you did mention some difference in message sizes; However, the size difference was because of the differing namespace in the request. To make sure I was always getting the same WSDL document, I downloaded it directly.
The service port node specifies https://www.beanstream.com/soap/ProcessTransaction.wsdl as the URL serving the WSDL document:
Using firefox or wget, I can only get it to serve WSDL containing the "bad" namespace attribute.<service name="ProcessTransaction"> <port name="TransClassSoapPort" binding="wsdlns:TransClassSoapBind +ing"> <soap:address location="https://www.beanstream.com/soap/ProcessT +ransaction.wsdl" /> </port> </service>
Are you sure both installations have SOAP::Lite version 0.69, SOAP::WSDL v1.22+, and that they're both receiving the same WSDL?
If that's true and the RedHat installation sends a different request, then RedHat might have patched either SOAP::Lite or SOAP::WSDL for distribution (not unheard of). You can force the cpan shell to install over what you have to make sure they're the same.
Have a look at the SOAP::Lite and SOAP::WSDL APIs to see if they allow you to manually override Envelope namespace attributes. If so, that should solve your problem. But really, based on my investigation, it's the server that is at fault.
-David
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: SOAP::Lite, but not the problem?
by justshootme (Initiate) on Nov 15, 2007 at 06:36 UTC |