This week's book giveaway is in the Jobs Discussion forum.
We're giving away four copies of Java Interview Guide and have Anthony DePalma on-line!
See this thread for details.
The moose likes Web Services and the fly likes Confused about axis deserializer (it don't work!) Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Confused about axis deserializer (it don Watch "Confused about axis deserializer (it don New topic

Confused about axis deserializer (it don't work!)

Luiz Sousa

Joined: Mar 24, 2005
Posts: 2
Hello all! New to the web services world, am using Axis 1.1 and Tomcat 5.0.25 to code a client for various web services (RPC types from, I can get the basic types to work fine (primitives, Strings, HashMap, etc), but anything above that causes the following exception stack:

- Exception:
org.xml.sax.SAXException: Deserializing parameter 'soapVal': could not find deserializer for type {urn:CompanyInfo}CompanyInfoResult
at org.apache.axis.message.RPCHandler.onStartChild(
at org.apache.axis.encoding.DeserializationContextImpl.startElement(
at org.apache.axis.message.SAX2EventRecorder.replay(
at org.apache.axis.message.MessageElement.publishToHandler(
at org.apache.axis.message.RPCElement.deserialize(
at org.apache.axis.message.RPCElement.getParams(
at org.apache.axis.client.Call.invoke(
at org.apache.axis.client.Call.invoke(
at org.apache.wsif.providers.soap.apacheaxis.WSIFOperation_ApacheAxis.invokeAXISRPCStyle(Lorg.apache.axis.client.Call;Lorg.apache.wsif.WSIFMessage;Lorg.apache.wsif.WSIFMessage;Lorg.apache.wsif.WSIFMessage;Lorg.apache.wsif.util.jms.WSIFJMSDestination Z(Unknown Source)
at org.apache.wsif.providers.soap.apacheaxis.WSIFOperation_ApacheAxis.invokeRequestResponseOperation(Lorg.apache.wsif.WSIFMessage;Lorg.apache.wsif.WSIFMessage;Lorg.apache.wsif.WSIFMessage Z(Unknown Source)
at org.apache.wsif.providers.soap.apacheaxis.WSIFOperation_ApacheAxis.executeRequestResponseOperation(Lorg.apache.wsif.WSIFMessage;Lorg.apache.wsif.WSIFMessage;Lorg.apache.wsif.WSIFMessage Z(Unknown Source)
at org.apache.wsif.base.WSIFClientProxy.invoke(Ljava.lang.Object;Ljava.lang.reflect.Method;[Ljava.lang.Object Ljava.lang.Object;(Unknown Source)
at $Proxy3.doCompanyInfo(Ljava.lang.String;Ljava.lang.String;Ljava.lang.String Lcom.emdweb.common.utils.test.companyInfo.CompanyInfoResult;(Unknown Source)

I've been trying to find answers everywhere (including the axis-dev mailing list) but everything is about the web service side and WSDD, which of course I have no access to because I am coding only the client

The web services work via the website, so I didn't think that's the problem. The WSDL is translated using WSDL2Java, and the resulting object ("CompanyInfoResut" in this example) has the following code:

* Get Custom Deserializer
public static org.apache.axis.encoding.Deserializer getDeserializer(
java.lang.String mechType,
java.lang.Class _javaType,
javax.xml.namespace.QName _xmlType) {
new org.apache.axis.encoding.ser.BeanDeserializer(
_javaType, _xmlType, typeDesc);

Since this is auto-genned by the Axis tool, why can't axis find it? Am I missing something? Is there anything (registering or otherwise) I can do client-side to make Axis "see"/"use" this deserializer?

Really confused as to why I can get the basic WS' to work fine, but others translated from the same tool (WSDL2Java) keep giving me this exception/fault, any thoughts?

Thanks in advance!
And cheers everyone

Rr Kumaran
Ranch Hand

Joined: Sep 17, 2001
Posts: 548
there can be various reasons like

1.if you use any custom types that cannot be handled by axis then they need to registered in client side's client-config.wsdd

2. is your WSDL adheres to BP 1.0+ which AXIS follows

RR Kumaran
SCJP 1.4
Luiz Sousa

Joined: Mar 24, 2005
Posts: 2
Oh okay, I was under the impressing that the deployment/wsdd files were for the server/service provider only, none of the articles and tutorials I had looked for mentioned a client-side one thank you! I will look into this promptly!
Very much appreaciated!

I agree. Here's the link:
subject: Confused about axis deserializer (it don't work!)
It's not a secret anymore!