axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chaudhri Rohit-CRC037 <Rohit.Chaud...@motorola.com>
Subject NullPointerException with Arrays
Date Tue, 28 May 2002 19:26:51 GMT
Hello,
I am using AXIS beta 2 with Jetty to deploy Web Services. I have a method in
my Web Service interface that expects as a paramter an Array of a Java
Object (called Attribute) that has 3 string fields in it. I get a
NullPointerException when invoking this method. The other methods in the Web
Service interface that donot have Array as an input parameter work fine. I
can also return Arrays successfully. Given below is the stack Trace that I
get at the server & the client and the typemapping that gets generated for
the Attibute object in deploy.wsdd. 

I would appreciate it if someone could help me figure out this problem.

Thanks
Rohit

<typeMapping
        xmlns:ns="http://content.dcvm.motorola.com"
        qname="ns:Attribute"
        type="java:com.motorola.dcvm.content.Attribute"
        serializer="org.apache.axis.encoding.ser.BeanSerializerFactory"
        deserializer="org.apache.axis.encoding.ser.BeanDeserializerFactory"
        encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
      />

<typeMapping
        xmlns:ns="http://www.motorola.com/dcvm/content"
        qname="ns:ArrayOf_tns1_Attribute"
        type="java:com.motorola.dcvm.content.Attribute[]"
        serializer="org.apache.axis.encoding.ser.ArraySerializerFactory"
        deserializer="org.apache.axis.encoding.ser.ArrayDeserializerFactory"
        encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
      />

Stack trace @ the server :

- Exception:
java.lang.NullPointerException
java.lang.NullPointerException
        at
org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider
.java:229)
        at
org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:
262)
        at
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrateg
y.java:71)
        at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:154)
        at org.apache.axis.SimpleChain.invoke(SimpleChain.java:121)
        at org.apache.axis.server.AxisServer.invoke(AxisServer.java:288)
        at
org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:57
6)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
        at
com.mortbay.Jetty.Servlet.ServletHolder.handle(ServletHolder.java:488
)
        at
com.mortbay.Jetty.Servlet.ServletHandler.handle(ServletHandler.java:4
88)
        at
com.mortbay.Jetty.Servlet.ServletHandler.handle(ServletHandler.java:3
17)
        at com.mortbay.HTTP.HandlerContext.handle(HandlerContext.java:956)
        at com.mortbay.HTTP.HandlerContext.handle(HandlerContext.java:913)
        at com.mortbay.HTTP.HttpServer.service(HttpServer.java:714)
        at com.mortbay.HTTP.HttpConnection.service(HttpConnection.java:521)
        at com.mortbay.HTTP.HttpConnection.handle(HttpConnection.java:347)
        at
com.mortbay.HTTP.SocketListener.handleConnection(SocketListener.java:
107)
        at com.mortbay.Util.ThreadedServer.handle(ThreadedServer.java:294)
        at
com.mortbay.Util.ThreadPool$PoolThreadRunnable.run(ThreadPool.java:61
3)
        at java.lang.Thread.run(Unknown Source)


Stack trace @ the client :

java.lang.NullPointerException
        at
org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:13
4)
        at
org.apache.axis.encoding.DeserializationContextImpl.endElement(Deserializati
onContextImpl.java:875)
        at
org.apache.xerces.parsers.SAXParser.endElement(SAXParser.java:1403)
        at
org.apache.xerces.validators.common.XMLValidator.callEndElement(XMLValidator
.java:1180)
        at
org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch(XM
LDocumentScanner.java:1256)
        at
org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScanner.
java:381)
        at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:952)
        at javax.xml.parsers.SAXParser.parse(SAXParser.java:374)
        at
org.apache.axis.encoding.DeserializationContextImpl.parse(DeserializationCon
textImpl.java:202)
        at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:428)
        at org.apache.axis.client.Call.invoke(Call.java:1919)
        at org.apache.axis.client.Call.invoke(Call.java:1690)
        at org.apache.axis.client.Call.invoke(Call.java:1608)
        at org.apache.axis.client.Call.invoke(Call.java:1169)
        at
com.motorola.dcvm.gen.store.StorageSoapBindingStub.query(StorageSoapB
indingStub.java:240)
        at
com.mot.labs.aal.dcvm.webservices.store.test.Test.main(test/Test.java
:33)

Mime
View raw message