cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From samuel_rg <srajaseka...@tsys.com>
Subject Re: issues with xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
Date Wed, 01 Oct 2008 18:58:05 GMT

Actually the WSDL and XSL is very long and so was not able to load it. I
looked up the elements and confirmed that getAccountTransactions is mapped
to a complex type.

And also by removing xsi:type the request is processed fine by CXF. Attached
is a successfully processed request by cxf(I have highlighted the changes
that I have made):

<?xml version="1.0" encoding="UTF-8" ?> 
 <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:getAccountTransactions
xmlns="http://api.prepaid.tsys.com/transaction/type"
xmlns:ns1="http://api.prepaid.tsys.com/transaction/type">
  <ns2:accountId
xmlns:ns2="http://api.prepaid.tsys.com/transaction">13976358</ns2:accountId> 
  </ns1:getAccountTransactions>
  </soapenv:Body>
  </soapenv:Envelope>



dkulp wrote:
> 
> 
> I'd have to see the wsdl to say for certain if the message is invalid or 
> not.   If getAccountTransactions is defined as an anonymous type in an 
> element, then this is definitely invalid. Again, I'd need to see the 
> wsdl/schema.
> 
> Dan
> 
> 
> On Wednesday 01 October 2008, samuel_rg wrote:
>> I am using CXF 2.1.1 and when the incoming XML request has notation
>> that uses xmlns:xsi the Schema Validation in CXF fails. Attached below
>> is the XML request that I am sending and the response that I got. Is
>> there anything wrong with the Request as it works fine with Axis and
>> we are migrating to CXF and it gives  this error.
>>
>>
>> Request:
>> <?xml version="1.0" encoding="UTF-8" ?>
>>  <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>
>> <getAccountTransactions xsi:type="ns1:getAccountTransactions"
>> xmlns="http://api.prepaid.tsys.com/transaction/type"
>> xmlns:ns1="http://api.prepaid.tsys.com/transaction/type">
>>   <ns2:accountId
>> xmlns:ns2="http://api.prepaid.tsys.com/transaction">13976358</ns2:acco
>>untId> </getAccountTransactions>
>>   </soapenv:Body>
>>   </soapenv:Envelope>
>>
>> Response:
>> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
>>   <soap:Body>
>>     <soap:Fault>
>>       <faultcode>soap:Client</faultcode>
>>       <faultstring>Unmarshalling Error: cvc-elt.4.2: Cannot resolve
>> 'ns1:getAccountTransactions' to a type definition for element
>> 'getAccountTransactions'. </faultstring>
>>     </soap:Fault>
>>   </soap:Body>
>> </soap:Envelope>
> 
> 
> 
> -- 
> J. Daniel Kulp
> Principal Engineer, IONA
> dkulp@apache.org
> http://www.dankulp.com/blog
> 
> 

-- 
View this message in context: http://www.nabble.com/issues-with-xmlns%3Axsi%3D%22http%3A--www.w3.org-2001-XMLSchema-instance%22-tp19764750p19766930.html
Sent from the cxf-user mailing list archive at Nabble.com.


Mime
View raw message