Null pointer exception sounds like something going wrong with the service itself and may not have anything to do with the SOAP implementation. I'd suggest creating a main() function in the service class and running it locally (by itself) to see if you still get the null pointer exception.
Cyrus On Mon, 2003-11-24 at 04:36, Tony Vieitez wrote: > Hi > > > > I am a newbie to soap and web services and I am getting an exception > that I cannot find the cause to. Is there anyone that can help? > > I have tried to build the simplest client and service possible. When > the client invokes a service, the xml that it gets back is a null > pointer exception. I just cannot find the cause of the problem. Here > is the exception: > > > > <?xmlversion='1.0' encoding='UTF-8'?> > > <SOAP-ENV:Envelope > xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xmlns:xsd="http://www.w3.org/2001/XMLSchema"> > > <SOAP-ENV:Body> > > <SOAP-ENV:Fault> > > <faultcode>SOAP-ENV:Server.Exception:</faultcode> > > <faultstring>java.lang.NullPointerException</faultstring> > > <faultactor>/soap/servlet/messagerouter</faultactor> > > </SOAP-ENV:Fault> > > </SOAP-ENV:Body> > > </SOAP-ENV:Envelope> > > > > Here is the deployment descriptor for the web service > > > > <isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment" > id="ani" type="message"> > > <isd:provider type="java" scope="Application" > methods="responsaQuery"> > > <isd:java class="altituderesponsatest.Processor" static="false"/> > > </isd:provider> > > > > <isd:faultListener>org.apache.soap.server.DOMFaultListener</isd:faultListener> > > </isd:service> > > > > Here is the web service: > > package altituderesponsatest; > > //import statements > > > > public class Processor { > > > > public void responsaQuery(Envelope env, SOAPContext req, SOAPContext > res) > > throws IOException, MessagingException { > > Document doc = new org.apache.xerces.dom.DocumentImpl(); > > Element response = doc.createElement("response"); > > Vector bodyEntries = new Vector(); > > bodyEntries.add(response); > > StringWriter writer = new StringWriter(); > > env.marshall(writer, null); > > res.setRootPart(writer.toString(), "text/xml"); > > } > > } > > > > Any help would be very much appreciated > > > > Tony > > > > > >