axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pietila.meg...@comcast.net
Subject stumped on deserializer problem
Date Thu, 04 Aug 2005 20:37:10 GMT
Thad,

I didn't see any answers to your question, so I'll add what I know, having just 
run into the same exception myself.  When I went to add the typeMapping into my 
.wsdd file, I found that adding the element qname didn't resolve anything--what 
I needed to do, was add the _complexType_ qname.

My setup is a bit simpler, since I (think I) can just use the regular Axis 
factories... I haven't managed to find much documentation on this stuff yet, 
though, so I guess I'll find out by trial and error.  I was able to get past 
this error, however, and move on to a brand-new error (ah, change is 
refreshing).

Example xml:

...
<BlankMessage xmlns:ns="http://www.blank.com/xml/" 
xsi:type="ns:ListOfBlankCustomerOfferTopElmt">
...

Matching .wsdd entry:

<typeMapping
  xmlns:ns="http://www.blank.com/xml/"
  qname="ns:ListOfBlankCustomerOfferTopElmt"
type="java:com.siebel.www.ListOfBlankCustomerOfferTopElmt"
serializer="org.apache.axis.encoding.ser.BeanSerializerFactory"
deserializer="org.apache.axis.encoding.ser.BeanDeserializerFactory"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>


Meghan Pietila
Granite Consulting


----Snippet from Thad's email:----

I've been through the archives and seen numerous references to this same 
problem.  No suggestions have helped or clarified any of this for me.  
(Judging from the frequency of this question, most other folks are stumped, 
too.)  Can someone clear this up?  I promise to write this up for the Axis 
docs if I ever getting it figured out.  Maybe that will close this thread.

Recently I've read to start/restart Tomcat (I'm using TC 5.5.9) but that 
hasn't worked.  I'm using Axis 1.2.1.

I have a large set of Java classes that talk to a Sun RPC legacy application.  
I want to access the legacy app via SOAP.  The Java classes were written 
without much (if any) thought to Beans (the Java API was to mimic the C/C++ 
API as closely as possible).  Hence BeanSerialization is not appropriate 
(methods like isFoo() or getFoo() often do not have an underlying foo 
member).  With the user's guide to custom serialization TBD, I have been 
using samples/encoding and Google finds as a guide.  When I adapt 
samples/encoding/TestSer.java to test my class, it works perfectly but when I 
try to call client-server via Axis, I get the exception:

"Caught RemoteException: org.xml.sax.SAXException: Deserializing parameter 
'pObjectID':  could not find deserializer for type 
{urn:oasSoapNamespace}ObjectID"

Here (in summary) are my files classes:

// deploy.wsdd
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
            xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
  <service name="OASService" provider="java:RPC">
    <parameter name="className" value="com.optix.soap.OASService"/>
    <parameter name="allowedMethods" value="*"/>
    <parameter name="scope" value="Session"/>
    <typeMappings>
      <typeMapping qname="ns:oasSoapNamespace" xmlns:ns="urn:oasSoapNamespace"
          languageSpecificType="java:com.optix.database.ObjectID"
          type="java:com.optix.database.ObjectID"
          serializer="com.optix.soap.encoding.ObjectIDSerFactory"
          deserializer="com.optix.soap.encoding.ObjectIDDeserFactory"
          encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
      <typeMapping qname="ns:oasSoapNamespace" xmlns:ns="urn:oasSoapNamespace"
          languageSpecificType="java:com.optix.database.OSType"
          type="java:com.optix.database.OSType"
          serializer="com.optix.soap.encoding.OSTypeSerFactory"
          deserializer="com.optix.soap.encoding.OSTypeDeserFactory"
          encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
    </typeMappings>
  </service>
</deployment>

Mime
View raw message