You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Doug Davis <du...@us.ibm.com> on 2002/03/07 19:08:15 UTC
Bug in serializing
Don't have time to look into this now but thought I'd
pass along what I have... given:
bug.java:
-----------------------------------------------------
import org.apache.axis.client.* ;
import java.util.* ;
import java.net.* ;
public class bug {
static public void main(String[] args) throws Exception {
Service service = new Service();
Call call = (Call) service.createCall();
call.setTargetEndpointAddress( new URL("http://localhost:8080") );
call.invoke( "foo", new Object[] { new bug() } );
}
}
Axis does detect that no serialize is specified for "bug", but
it still tries to send a message out on the wire and the
message includes the error:
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV
="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd
="http://www.w3.org/2001/XMLSchema" xmlns:xsi
="http://www.w3.org/2001/XMLSchema-instance">
<SOAP-ENV:Body>
<SOAP-ENV:Fault>
<faultcode xmlns:ns1
="http://xml.apache.org/axis/">ns1:Server.userException</faultcode>
<faultstring>java.io.IOException: No serializer found for class bug in
registry
org.apache.axis.encoding.SerializationContextImpl@59fd51</faultstring>
<detail>
<ns2:stackTrace xmlns:ns2
="http://xml.apache.org/axis/">java.io.IOException: No serializer found for
class bug in registry
org.apache.axis.encoding.SerializationContextImpl@59fd51
at
org.apache.axis.encoding.SerializationContextImpl.serializeActual(Unknown
Source)
at
org.apache.axis.encoding.SerializationContextImpl.serialize(Unknown Source)

at
org.apache.axis.encoding.SerializationContextImpl.outputMultiRefs(Unknown
Source)
at org.apache.axis.message.SOAPEnvelope.outputImpl(Unknown Source)

at org.apache.axis.message.MessageElement.output(Unknown Source)
at org.apache.axis.SOAPPart.getAsString(Unknown Source)
at org.apache.axis.SOAPPart.getAsBytes(Unknown Source)
at org.apache.axis.Message.getContentLength(Unknown Source)
at org.apache.axis.transport.http.HTTPSender.invoke(Unknown Source)

at org.apache.axis.strategies.InvocationStrategy.visit(Unknown
Source)
at org.apache.axis.SimpleChain.doVisiting(Unknown Source)
at org.apache.axis.SimpleChain.invoke(Unknown Source)
at org.apache.axis.client.AxisClient.invoke(Unknown Source)
at org.apache.axis.client.Call.invoke(Unknown Source)
at org.apache.axis.client.Call.invoke(Unknown Source)
at org.apache.axis.client.Call.invoke(Unknown Source)
at org.apache.axis.client.Call.invoke(Unknown Source)
at bug.main(bug.java:11)
</ns2:stackTrace>
</detail>
</SOAP-ENV:Fault>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
Kind of neat :-)
-Dug