Sir,
Thank you for your reply. I understand it is a bug and I will also track its activity.
But I am
highly dependent on AXIS now. Can you please suggest me a workaround? or a pointer on
where would
I need a change? I am using AXIS1.1RC2 one tomcat apache linux
My SOAP response is working fine when I simple send a SOAPRequest. ( I used XMLSPY to
send a SOAP
request and recieve it)
The SOAP response is in this format
<publications>
<item>
<pubid>34234</pubid>
<title>afdadfs</title>
<persons>
<item>
<perid>33<perid>
<personname>asfasdfasdfasdf</personname>
</item>
<item>
<perid>33<perid>
<personname>asfasdfasdfasdf</personname>
</item>
</persons>
</item>
<item>
<pubid>342334244</pubid>
<title>afdadfasdfasdffs</title>
</item>
<publications>
My data structures are:
public class Person
{
private int perID;
private String personName;
}
public class Publication
{
private int pubID;
private String title;
Person [] person;
int year;
}
-----------------
My WSDL is attached
Web service is functioning perfectly at
http://dblpseer.ist.psu.edu/ws/services/DBLPSeerPort?WSDL
---------------
I am getting SOAP responses when I send the requests but when I am using a client, It
gives me
this error.
for eg. My searthTitle takes in a searchString (SearchTitleRequestType )and returns a
Publication
Array. Hence when it executes the function (does the RPC) and when it returns it gives
me this
error
//MyClient.jsp
DBLPSeerWebService service = new DBLPSeerWebServiceLocator();
DBLPSeerPortType port = service.getDBLPSeerPort();
SearchTitleRequestType body = new SearchTitleRequestType();
body.setSearchString(searchString);
Publication temp[];
SearchTitleResponseType strp = port.searchTitle(body);
temp = strp.getPublications();<<<<<<<<<<<<<####1 : I think it gives an error here.
//And then I print this array
[EMAIL PROTECTED]: Or over here
while(temp[i]!=null){
<%= temp[i].getPubID() %>"><b><%= temp[i].getTitle() %></b>
<%= temp[i].getYear() %><br />
<span class="f">Authors/Editors: </span>
<% int j=0;
while(temp[i].getPersons()[j]!=null){
<%= temp[i].getPersons()[j].getPerID() %>::<%=
temp[i].getPersons([j].getPersonName() %>,
<%
j++;
}
i++
}
I think since the Publications element is an SOAP array and it contains a Persons
element which
contains a SOAPArray, the problem is coming...
Can you please give me a pointer or a workaround???? It will be HIGHLY WORSHIPPED at
this point of
time.
THANKS
Jinesh
ps. I tried changing my WSDL which would put the PERSON and PUBLICATION elements
inside the ARRAYS
so that it does not give <item> but gives <publication> (under <publications>) and
<person> (under
<persons>) BUT then it did not create the getters and setters functions at all. and I
could
proceed!!
AnyBODY ANY HELP!! will be appreciated.....
--- David Gilbert <[EMAIL PROTECTED]> wrote:
> There are a few bugs still outstanding regarding deserializing java bean
> arrays. Please see http://nagoya.apache.org/bugzilla/index.html for a
> listing and the latest status.
>
> -----Original Message-----
> From: Jinesh Varia [mailto:[EMAIL PROTECTED]
> Sent: Thursday, March 13, 2003 4:59 PM
> To: [EMAIL PROTECTED]
> Cc: [EMAIL PROTECTED]
> Subject: was this bug fixed?? deserializing beans within an array in a
> bean
>
>
> I am using AXISRC2. PLEASE somebody inform me whether this but is fixed or
> not??
> thanks
>
> org.xml.sax.SAXException: No deserializer defined for array type Publication
> at org.apache.axis.AxisFault.makeFault(AxisFault.java:129)
> at org.apache.axis.client.Call.invoke(Call.java:2237)
> at org.apache.axis.client.Call.invoke(Call.java:2133)
> at org.apache.axis.client.Call.invoke(Call.java:1656)
> at DBLPSeerClient.DBLPSeerBindingStub.searchTitle(DBLPSeerBindingStub
>
> =====
> -----------------------------------------------------------------
> Jinesh Varia
> Graduate Student, Information Systems
> Pennsylvania State University
> Email: [EMAIL PROTECTED]
> -----------------------------------------------------------------
> 'Self is the author of its actions.'
>
> __________________________________________________
> Do you Yahoo!?
> Yahoo! Web Hosting - establish your business online
> http://webhosting.yahoo.com
>
=====
-----------------------------------------------------------------
Jinesh Varia
Graduate Student, Information Systems
Pennsylvania State University
Email: [EMAIL PROTECTED]
-----------------------------------------------------------------
'Self is the author of its actions.'
__________________________________________________
Do you Yahoo!?
Yahoo! Web Hosting - establish your business online
http://webhosting.yahoo.com<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions targetNamespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:apachesoap="http://xml.apache.org/xml-soap"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:dblpxsd="http://dblpseer.ist.psu.edu/dblpseer/schemas/ws.xsd"
xmlns:dblpns="http://dblpseer.ist.psu.edu/dblpseer/schemas/">
<wsdl:types>
<schema targetNamespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/ws.xsd" xmlns="http://www.w3.org/2001/XMLSchema">
<!-- Common elements -->
<complexType name="Person">
<sequence>
<element name="perID" type="xsd:int"/>
<element name="personName" nillable="true" type="xsd:string"/>
</sequence>
</complexType>
<complexType name="Publication">
<sequence>
<element name="pubID" type="xsd:int"/>
<element name="title" type="xsd:string"/>
<element name="Persons" type="dblpxsd:PersonArray"/>
<element name="year" type="xsd:int"/>
</sequence>
</complexType>
<!-- Array elements -->
<complexType name="PublicationArray">
<complexContent>
<restriction base="soapenc:Array">
<attribute ref="soapenc:arrayType" wsdl:arrayType="dblpxsd:Publication[]"/>
</restriction>
</complexContent>
</complexType>
<complexType name="PersonArray">
<complexContent>
<restriction base="soapenc:Array">
<attribute ref="soapenc:arrayType" wsdl:arrayType="dblpxsd:Person[]"/>
</restriction>
</complexContent>
</complexType>
<complexType name="keywordArray">
<complexContent>
<restriction base="soapenc:Array">
<attribute ref="soapenc:arrayType" wsdl:arrayType="xsd:string[]"/>
</restriction>
</complexContent>
</complexType>
<!-- searchPerson Request and Response -->
<complexType name="searchPersonRequestType">
<sequence>
<xsd:element name="searchString" type="xsd:string" />
</sequence>
</complexType>
<complexType name="searchPersonResponseType">
<sequence>
<element name="Persons" type="dblpxsd:PersonArray"/>
</sequence>
</complexType>
<!-- searchTitle Request and Response -->
<complexType name="searchTitleRequestType">
<sequence>
<element name="searchString" type="xsd:string" />
</sequence>
</complexType>
<complexType name="searchTitleResponseType">
<sequence>
<element name="Publications" type="dblpxsd:PublicationArray" />
</sequence>
</complexType>
<!-- getAllPublications Request and Response -->
<complexType name="getAllPublicationsRequestType">
<sequence>
<element name="perID" type="xsd:integer" />
</sequence>
</complexType>
<complexType name="getAllPublicationsResponseType">
<sequence>
<element name="Publications" type="dblpxsd:PublicationArray" />
</sequence>
</complexType>
<!-- searchKeywords Request and Response -->
<!-- Should search Title, journal, booktitle, personname-->
<complexType name="searchKeywordsRequestType">
<sequence>
<element name="keywords" type="dblpxsd:keywordArray" />
</sequence>
</complexType>
<complexType name="searchKeywordsResponseType">
<sequence>
<element name="Publications" type="dblpxsd:PublicationArray" />
</sequence>
</complexType>
<!-- Root elements -->
<element name="searchPersonRequest" type="dblpxsd:searchPersonRequestType" nillable="true" />
<element name="searchPersonResponse" type="dblpxsd:searchPersonResponseType" nillable="true" />
<element name="searchTitleRequest" type="dblpxsd:searchTitleRequestType" nillable="true" />
<element name="searchTitleResponse" type="dblpxsd:searchTitleResponseType" nillable="true" />
<element name="getAllPublicationsRequest" type="dblpxsd:getAllPublicationsRequestType" nillable="true" />
<element name="getAllPublicationsResponse" type="dblpxsd:getAllPublicationsResponseType" nillable="true" />
<element name="searchKeywordsRequest" type="dblpxsd:searchKeywordsRequestType" nillable="true" />
<element name="searchKeywordsResponse" type="dblpxsd:searchKeywordsResponseType" nillable="true" />
</schema>
</wsdl:types>
<wsdl:message name="searchPersonInput">
<wsdl:part name="body" element="dblpxsd:searchPersonRequest"/>
</wsdl:message>
<wsdl:message name="searchPersonOutput">
<wsdl:part name="body" element="dblpxsd:searchPersonResponse"/>
</wsdl:message>
<wsdl:message name="searchTitleInput">
<wsdl:part name="body" element="dblpxsd:searchTitleRequest"/>
</wsdl:message>
<wsdl:message name="searchTitleOutput">
<wsdl:part name="body" element="dblpxsd:searchTitleResponse"/>
</wsdl:message>
<wsdl:message name="getAllPublicationsInput">
<wsdl:part name="body" element="dblpxsd:getAllPublicationsRequest"/>
</wsdl:message>
<wsdl:message name="getAllPublicationsOutput">
<wsdl:part name="body" element="dblpxsd:getAllPublicationsResponse"/>
</wsdl:message>
<wsdl:message name="searchKeywordsInput">
<wsdl:part name="body" element="dblpxsd:searchKeywordsRequest"/>
</wsdl:message>
<wsdl:message name="searchKeywordsOutput">
<wsdl:part name="body" element="dblpxsd:searchKeywordsResponse"/>
</wsdl:message>
<wsdl:portType name="DBLPSeerPortType">
<wsdl:operation name="getAllPublications">
<wsdl:input message="dblpns:getAllPublicationsInput" name="getAllPublicationsInput"/>
<wsdl:output message="dblpns:getAllPublicationsOutput" name="getAllPublicationsOutput"/>
</wsdl:operation>
<wsdl:operation name="searchPerson">
<wsdl:input message="dblpns:searchPersonInput" name="searchPersonInput"/>
<wsdl:output message="dblpns:searchPersonOutput" name="searchPersonOutput"/>
</wsdl:operation>
<wsdl:operation name="searchTitle">
<wsdl:input message="dblpns:searchTitleInput" name="searchTitleInput"/>
<wsdl:output message="dblpns:searchTitleOutput" name="searchTitleOutput"/>
</wsdl:operation>
<wsdl:operation name="searchKeywords">
<wsdl:input message="dblpns:searchKeywordsInput" name="searchKeywordsInput"/>
<wsdl:output message="dblpns:searchKeywordsOutput" name="searchKeywordsOutput"/>
</wsdl:operation>
</wsdl:portType>
<!--Define the binding for each operation-->
<wsdl:binding name="DBLPSeerBinding" type="dblpns:DBLPSeerPortType">
<wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
<wsdl:operation name="getAllPublications">
<wsdlsoap:operation soapAction=""/>
<wsdl:input name="getAllPublicationsInput">
<wsdlsoap:body namespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/" use="literal"/>
</wsdl:input>
<wsdl:output name="getAllPublicationsOutput">
<wsdlsoap:body namespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/" use="literal"/>
</wsdl:output>
</wsdl:operation>
<wsdl:operation name="searchPerson">
<wsdlsoap:operation soapAction=""/>
<wsdl:input name="searchPersonInput">
<wsdlsoap:body namespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/" use="literal"/>
</wsdl:input>
<wsdl:output name="searchPersonOutput">
<wsdlsoap:body namespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/" use="literal"/>
</wsdl:output>
</wsdl:operation>
<wsdl:operation name="searchTitle">
<wsdlsoap:operation soapAction=""/>
<wsdl:input name="searchTitleInput">
<wsdlsoap:body namespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/" use="literal"/>
</wsdl:input>
<wsdl:output name="searchTitleOutput">
<wsdlsoap:body namespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/" use="literal"/>
</wsdl:output>
</wsdl:operation>
<wsdl:operation name="searchKeywords">
<wsdlsoap:operation soapAction=""/>
<wsdl:input name="searchKeywordsInput">
<wsdlsoap:body namespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/" use="literal"/>
</wsdl:input>
<wsdl:output name="searchKeywordsOutput">
<wsdlsoap:body namespace="http://dblpseer.ist.psu.edu/dblpseer/schemas/" use="literal"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<!-- wsdl:service -->
<wsdl:service name="DBLPSeerWebService">
<!-- connect it to the binding "DBLPSeerBinding" above -->
<wsdl:port binding="dblpns:DBLPSeerBinding" name="DBLPSeerPort">
<!-- give the binding an network address -->
<wsdlsoap:address location="http://dblpseer.ist.psu.edu/ws/services/DBLPSeerPort"/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>