I�ve attached the SOAP Message and the WSDL file. WSDL is so large because I
tried several possibilities in one Service.

 <<SOAP_Req.xml>> 
 <<WorkflowService.wsdl>> 

 -----Original Message-----
From:   blake biesecker [mailto:[EMAIL PROTECTED]] 
Sent:   Montag, 24. Juni 2002 16:09
To:     '[EMAIL PROTECTED]'
Subject:        RE: .NET Client does not deserialize typed Array

Christian,

It would be helpful to also see the soap message returned
to the client and your wsdl.

Blake

> -----Original Message-----
> From: Christian Schmitz [mailto:[EMAIL PROTECTED]]
> Sent: Monday, June 24, 2002 3:10 AM
> To: '[EMAIL PROTECTED]'
> Subject: .NET Client does not deserialize typed Array
> 
> 
> Hallo,
> last week I wrote to this user list because .Net won't deserialize
> java.util.vector. The most recommend solution was to use typed arrays
> instead of a vector. I tried it, but this doesn't work too. 
> If anybody could
> help, I'm going to go mad :o)
> 
> Here is the infected code extract and a description of the I 
> tried to use
> it:
> 
> This are my Java Web Service (JobInfo is a JavaBean, 
> containing Data Types
> like String, long and Date)
>  
>         
>         public JobInfo[] getPendingJobInfoListArray() 
>         {
>               CreateTestJobInfo tj = new CreateTestJobInfo();
> JobInfo[] JobArray = 
> {(JobInfo)tj.getJobInfoTestObject("Pending Job Nummer
> 1"), (JobInfo)tj.getJobInfoTestObject("Pending Job Nummer
> 2"),(JobInfo)tj.getJobInfoTestObject("Pending Job Nummer 3") };
>               return JobArray;        
>         } 
> 
> This is the second way I tried, because there was posted a tip to use
> collection and create a Array of it. But this way Tomcat throws a
> ClassCastException.
> 
>         public JobInfo[] getRunningJobInfoListArray() 
>         {
>               Collection result = new ArrayList();
>               CreateTestJobInfo tj = new CreateTestJobInfo();
>               result.add( 
> (JobInfo)tj.getJobInfoTestObject("Running Job
> Nummer 1") );
>               result.add( 
> (JobInfo)tj.getJobInfoTestObject("Running Job
> Nummer 2") );
>               result.add( 
> (JobInfo)tj.getJobInfoTestObject("Running Job
> Nummer 3") );
>               return (JobInfo[]) result.toArray();                    
>         } 
> 
> In deployment descriptor I mapped the BeanSerializer from 
> Axis to Serialize
> the Object:
> 
>  <service name="WorkflowService" provider="java:RPC">
>       <namespace>http://mySchema.de/</namespace>
>       <typeMapping
>         xmlns:ns="http://mySchema.de/xsd";
>         qname="ns:JobInfo"
>         type="java:com.pb.bs.workflow.webservice.JobInfo"
>         
> serializer="org.apache.axis.encoding.ser.BeanSerializerFactory"
>         
> deserializer="org.apache.axis.encoding.ser.BeanDeserializerFactory"
>         encodingStyle="http://schemas.xmlsoap.org/soap/encoding/";
>       />
> ...
> 
> I deployed the Service using axis beta2 in Tomcat 4.0.3 and 
> created the WSDL
> file of the deployed service with org.apache.axis.wsdl.Java2WSDL
> 
> Then I used the WSDL file to create a Proxy with wsdl.exe of the .NET
> Framework.
> 
> And this is the error my app caught when I try to invoke the service:
> 
> System.InvalidOperationException: There is an error in XML 
> document (5, 5).
> ---> System.InvalidOperationException: The specified type was not
> recognized: name='JobInfo', namespace='http://mySchema.de/xsd', at
> <getPendingJobInfoListArrayReturn xmlns=''>.
>    at
> System.Xml.Serialization.XmlSerializationReader.GetPrimitiveTy
> pe(XmlQualifie
> dName typeName)
>    at System.Xml.Serialization.XmlSerializationReader.ReadArray()
>    at
> System.Xml.Serialization.XmlSerializationReader.ReadReferencin
> gElement(Strin
> g name, String ns, Boolean elementCanBeType, String& fixupReference)
>    at
> System.Xml.Serialization.XmlSerializationReader.ReadReferencin
> gElement(Strin
> g& fixupReference)
>    at
> Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerialization
> Reader1.Read36
> _getPendingJobInfoListArrayResponse()
>    --- End of inner exception stack trace ---
> 
> 
> I watched the TCP Channel using tcpmon of Axis and if it 
> helps I can post
> the SOAP Message returned to client!
> 
> 
> Christian
> 

Attachment: SOAP_Req.xml
Description: Binary data

Attachment: WorkflowService.wsdl
Description: Binary data

Reply via email to