Hi all, I have created a web service using Axis2 and JiBX. The service returns a collection of objects representing currencies.
When I am interacting with Java clients using JiBX as well everything works well. However, if I am trying to use a .Net Client (created with Visual Studio 2005), I am receiving erroneous data. In more detail, the client creates the right number of objects (here: currencies), but fails to fill them with data (i.e. objectid and domainID are always null). If I am using a different data binding, i.e. ADB I am fine and the .Net client works well. However, I would prefer working with JiBX as this would allow me to use existing DTOs. Looking at the SOAP responses (see below) for both JiBX and ADB it turns out that ADB includes more information on namespace and type information on the elements of the collection. I suspect (<> know) that this is part of the problem. Any input on the following questions would be appreciated, since I am really stuck here: A) Can anyone tell me what causes the .Net client to fail? I tought the WSDL is ok for usage with .Net, but I am no longer sure... B) Did I make any errors configuring JIBX or setting up the WSDL (Note: I can still change the WSDL if necessary)? C) If the problems are really due to the missing type information, can I get JiBX to insert it in the SOAP response? Here are the responses that I get (cf. WSDL at end of e-mail)... ...when using JiBX: <soapenv:Envelope xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope"> <soapenv:Body> <_:getCurrenciesResponse xmlns:_="http://dataapi.contentsoftware.com/AuxillaryAPI/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <currency xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <objectid>5</objectid> <domainId>USD</domainId> </currency> </_:getCurrenciesResponse> </soapenv:Body> </soapenv:Envelope> ...when using ADB: <?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope"> <soapenv:Body> <ns3:getCurrenciesResponse xmlns:ns3="http://dataapi.contentsoftware.com/AuxillaryAPI/"> <currency xmlns:ns1="http://dataapi.contentsoftware.com/BasicTypes" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="ns1:Currency"> <ns1:objectId>5</ns1:objectId> <ns1:domainId>USD</ns1:domainId> </currency> </ns3:getCurrenciesResponse> </soapenv:Body> </soapenv:Envelope> I am using the following binding definition: <binding force-classes="true" xmlns:basic="http://dataapi.contentsoftware.com/BasicTypes" xmlns:util="http://dataapi.contentsoftware.com/UtilityTypes"> <mapping name="getCurrencies_fault" class="com.contentsoftware.dataapi.ws.errors.GetCurrenciesFault0"> <namespace prefix="api" uri="http://dataapi.contentsoftware.com/AuxillaryAPI/" default="elements" /> <value name="type" get-method="getType" set-method="setType" usage="optional"/> <value name="message" get-method="getMessage" set-method="setMessage" usage="optional"/> <value name="additionalInfo" get-method="getAdditionalInfo" set-method="setAdditionalInfo" usage="optional"/> </mapping> <mapping abstract="true" type-name="basic:Currency" class="com.contentsoftware.datainterface.dto.Currency"> <value name="objectid" get-method="getObjectId" set-method="setObjectId" usage="required" /> <value name="domainId" get-method="getDomainId" set-method="setDomainId" usage="required" /> <value name="shortDescriptor" get-method="getShortDescriptor" set-method="setShortDescriptor" usage="optional" /> <value name="longDescriptor" get-method="getLongDescriptor" set-method="setLongDescriptor" usage="optional" /> </mapping> </binding> And finally this is the WSDL of the web service: <wsdl:types> <xsd:schema targetNamespace="http://dataapi.contentsoftware.com/AuxillaryAPI/" xmlns:basic="http://dataapi.contentsoftware.com/BasicTypes" xmlns:util="http://dataapi.contentsoftware.com/UtilityTypes"> <xsd:import namespace="http://dataapi.contentsoftware.com/BasicTypes" schemaLocation="BasicAPITypes.xsd"/> <xsd:import namespace="http://dataapi.contentsoftware.com/UtilityTypes" schemaLocation="UtilityTypes.xsd"/> <xsd:element name="getCurrenciesResponse"> <xsd:complexType> <xsd:sequence> <xsd:element name="currency" type="basic:Currency" minOccurs="0" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:element name="getCurrencies_fault"> <xsd:complexType> <xsd:sequence> <xsd:element name="error" type="util:DataAPIFault"/> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:element name="getCurrencies"> <xsd:complexType /> </xsd:element> </xsd:schema> </wsdl:types> <wsdl:message name="getCurrenciesResponse"> <wsdl:part name="parameters" element="tns:getCurrenciesResponse"/> </wsdl:message> <wsdl:message name="getCurrencies_fault"> <wsdl:part name="parameters" element="tns:getCurrencies_fault"/> </wsdl:message> <wsdl:message name="getCurrenciesRequest"> <wsdl:part name="parameters" element="tns:getCurrencies" /> </wsdl:message> Regards and thanks in advance, Peter Jung Software Consultant Phone: +49 6172 662621-23 Fax: +49 6172 662621-99 http://www.content-software.com Content Software GmbH Benzstraße 1, D-61352 Bad Homburg v. d. H. Amtsgericht Bad Homburg HRB 6985, USt-IdNr. DE209233819 Geschäftsführer der Gesellschaft sind: Konrad Hepp & Torsten Greiff ------------------------------------------------------------------------------ Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA -OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise -Strategies to boost innovation and cut costs with open source participation -Receive a $600 discount off the registration fee with the source code: SFAD http://p.sf.net/sfu/XcvMzF8H _______________________________________________ jibx-users mailing list jibx-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jibx-users