*
The moose likes Web Services and the fly likes Cannot invoke method get() on null object Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Cannot invoke method get() on null object" Watch "Cannot invoke method get() on null object" New topic
Author

Cannot invoke method get() on null object

Rajeev Ravindran
Ranch Hand

Joined: Aug 27, 2002
Posts: 455
hey,

I have a webservice client program. I used axis wsdl2java to generate client. I am able to run the client and display value returned by webservice. I used juni test class to connect to webservice through my webservice client.
If i deploy the same client jar in a 3rd party software and access my webservice through this my client program Im getting the following exception. I am not seeing any calls being made to webservice implementation class.. I am using maven assembly plugin to create the jars, so the chances of missing dependent jars are minimal.


2010-02-08 23:34:24,270 [main] DEBUG org.apache.axis.SOAPPart - current form is FORM_SOAPENVELOPE
2010-02-08 23:34:24,270 [main] DEBUG org.apache.axis.i18n.ProjectResourceBundle - org.apache.axis.i18n.resource::handleGetObject(toAxisFault00)
2010-02-08 23:34:24,270 [main] DEBUG org.apache.axis.enterprise - Mapping Exception to AxisFault
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server
faultSubcode:
faultString: java.lang.NullPointerException: Cannot invoke method get() on null object
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:java.lang.NullPointerException: Cannot invoke method get() on null object
at org.apache.axis.message.SOAPFaultBuilder.createFault(SOAPFaultBuilder.java:222)
at org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:129)
at org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:1087)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:601)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1772)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2923)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:645)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:140)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:508)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:807)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:107)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1205)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:522)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:395)
at org.apache.axis.encoding.DeserializationContext.parse(DeserializationContext.java:227)
at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:696)
at org.apache.axis.Message.getSOAPEnvelope(Message.java:435)
at org.apache.axis.transport.http.HTTPSender.readFromSocket(HTTPSender.java:796)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:144)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)


i am running out of ideas. I found few links googling but the issue is not yet resolved. Any help is appreciated.

Thanks,
Rajeev

SCJP, SCWCD, SCBCD, Oracle Certified Professional (SQL n PL/SQL)
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Cannot invoke method get() on null object
 
Similar Threads
faultString: SOAP-ERROR: Encoding: object hasn't 'code' property
Axis Fault
Class cast Exceptions while accessing services - AXIS 1.4
SOAP processing failure, error id = 1001
Server.UserException on invoking a webservice