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 Aravind Nallan <ar...@openwave.com> on 2004/05/27 18:27:25 UTC

Arrays in Faults

When my server returns a fault which has an array in it, i get a
NullPointerException

Response:
<?xml version="1.0" encoding="UTF-8"?>
<env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:enc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns0="urn:opwv"
env:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><env:Body><env
:Fault
xsi:type="env:Fault"><faultcode>env:Server</faultcode><faultstring>com.openw
ave.mms.webservice.NoSuchItemException</faultstring><detail><ns0:NoSuchItemE
xception xsi:type="ns0:NoSuchItemException"><mediaIds
href="#ID1"/></ns0:NoSuchItemException></detail></env:Fault><ns0:ArrayOfstri
ng id="ID1" xsi:type="enc:Array" enc:arrayType="xsd:string[1]"><item
xsi:type="xsd:string">abcd</item></ns0:ArrayOfstring></env:Body></env:Envelo
pe>

Exception:
AxisFault
 faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
 faultSubcode:
 faultString: java.lang.NullPointerException
 faultActor:
 faultNode:
 faultDetail:
        {http://xml.apache.org/axis/}stackTrace:
java.lang.NullPointerException
        at org.apache.axis.client.Call.invokeEngine(Call.java:2591)
        at org.apache.axis.client.Call.invoke(Call.java:2553)
        at org.apache.axis.client.Call.invoke(Call.java:2248)
        at org.apache.axis.client.Call.invoke(Call.java:2171)
        at org.apache.axis.client.Call.invoke(Call.java:1691)
        at opwv.GalleryBindingStub.fetchItems(GalleryBindingStub.java:538)
        at GalleryClient.main(GalleryClient.java:39)


java.lang.NullPointerException
        at org.apache.axis.AxisFault.makeFault(AxisFault.java:129)
        at org.apache.axis.client.Call.invoke(Call.java:2251)
        at org.apache.axis.client.Call.invoke(Call.java:2171)
        at org.apache.axis.client.Call.invoke(Call.java:1691)
        at opwv.GalleryBindingStub.fetchItems(GalleryBindingStub.java:538)
        at GalleryClient.main(GalleryClient.java:39)
Caused by: java.lang.NullPointerException
        at org.apache.axis.client.Call.invokeEngine(Call.java:2591)
        at org.apache.axis.client.Call.invoke(Call.java:2553)
        at org.apache.axis.client.Call.invoke(Call.java:2248)
        ... 4 more

Is this a known bug? If so are there any workarounds?

Thanks
Aravind