You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Tony Liu <li...@gmail.com> on 2008/04/09 12:08:48 UTC

One last hurdle, hopefully, from axis to axis2.

For the last three weeks, I have been working on a project of migrating our
web service from axis to axis2. The client application built on Python
invokes operations exposed by the axis service, using RPC. I have to say
that it was difficult as hell, since axis2 documentations are just too brief
to have any good use, leave alone the "Migrating from axis to axis2"
documentation. After three weeks of try-and-error, things are getting much
more encouraging.

One last hurdle, hopefully.

Right now, all the method calls that take no arguments, primitive arguments
and explicit object (not java.lang.Object) arguments work just fine, but the
ones that take a generic object argument doesn't. For example, I have a
class as follows,

public class QueryNode implements Serialiable {
private Object leftOperant;
private int operator;
private Object rightOperant;
..........
}

The wsdl file for QueryNode,
<complexType>
<sequence>
<element name="leftOperant" nillable="true" type="anyType"/>
<element name="operator" type="int"/>
<element name="rightOperant" nillable="true" type="anyType"/>
...

The actual objects leftOperant and rightOperant take are String and
QueryNode. It works all fine in Axis. Axis is able to deserialize them to
the correct class instances, either String or QueryNode. But Axis2 gives you
instances of javax.activation.DataHandler, that I don't understand why! I
suspect it has something to do with "anyType", but... Can you please help?

Thanks,

Tony