4 Replies Latest reply on Feb 14, 2005 5:35 PM by guptah

    Error while executing WS client

    guptah Newbie

      Hi,

      I am new to web services and am trying to write a simple Hello webservice. The web service deploys fine but when I try to call it using client, I get the following error: -

      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 java.util.Hashtable.put(Hashtable.java:396)
      at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.setProperty(SAXParserImpl.java:395)
      at org.apache.axis.encoding.DeserializationContextImpl.parse(DeserializationContextImpl.java:246)
      at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:538)
      at org.apache.axis.Message.getSOAPEnvelope(Message.java:376)
      at org.apache.axis.client.Call.invokeEngine(Call.java:2583)
      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 client.CPRWebServiceClient.main(CPRWebServiceClient.java:69)


      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 client.CPRWebServiceClient.main(CPRWebServiceClient.java:69)
      Caused by: java.lang.NullPointerException
      at java.util.Hashtable.put(Hashtable.java:396)
      at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.setProperty(SAXParserImpl.java:395)
      at org.apache.axis.encoding.DeserializationContextImpl.parse(DeserializationContextImpl.java:246)
      at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:538)
      at org.apache.axis.Message.getSOAPEnvelope(Message.java:376)
      at org.apache.axis.client.Call.invokeEngine(Call.java:2583)
      at org.apache.axis.client.Call.invoke(Call.java:2553)
      at org.apache.axis.client.Call.invoke(Call.java:2248)

      I am using JBoss 4.0.1, Apache axis 1.1, JWSDP 1.5.

      Here is jaxrpc-ri.xml :-

      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE webServices>








      Here is config-interface.xml:-
      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE configuration>







      Here is generated WSDL:-

      <?xml version="1.0" encoding="UTF-8" ?>
      - <definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="urn:foo" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" name="CPRWebServices" targetNamespace="urn:foo">

      -





      -


      -


      -


      -
      -



      -




      -
      <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc" />
      -
      <soap:operation soapAction="" />
      -
      <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" use="encoded" namespace="urn:foo" />

      -
      <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" use="encoded" namespace="urn:foo" />


      -
      <soap:operation soapAction="" />
      -
      <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" use="encoded" namespace="urn:foo" />

      -
      <soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" use="encoded" namespace="urn:foo" />



      -
      -
      <soap:address xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" location="http://gupta:8080/cprwebservices/cprws" />




      Any help is most appreciated.

      Thanks,
      Himanshu