Did you change the server environment any? In particular, did you copy the soap.jar somewhere new? You should only have a single place from which your servlet container can load the Apache SOAP classes, and it should be the webapp into which you deployed Apache SOAP. Different locations from which the container load classes are serviced by different class loaders, which causes serious problems.
Scott Nichol Do not send e-mail directly to this e-mail address, because it is filtered to accept only mail from specific mail lists. ----- Original Message ----- From: "tony vieitez" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, November 24, 2003 4:17 PM Subject: null pointer exception > Hi guys > > Thanks for your insightful responses - but now my problem has moved on > somewhat. I have left behind (or maybe now not yet reaching!) the null > pointer exception and am now experiencing a 'no signature match > exception': > > <faultstring>Exception while handling service request: > altituderesponsatest.Processor.responsaQuery(org.apache.soap.Envelope,or > g.apache.soap.rpc.SOAPContext,org.apache.soap.rpc.SOAPContext) -- no > signature match</faultstring> > > > I have altered all parts involved in the application in an attempt to > overcome the null pointer exception (including implementing a generic > way of creating the document - thanks Scott). Here are the new bits: > > Deployment Descriptor: > > <isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment" > id="urn:Processor" 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:faultLis > tener> > </isd:service> > > Message sent by client to server: > > <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/"> > <s:Body> > <responsaQuery number="0208233826" xmlns="urn:Processor"/> </s:Body> > </s:Envelope> > > Server: > > package altituderesponsatest; > > public class Processor { > > public void responsaQuery(Envelope env, SOAPContext req, SOAPContext > res) > throws Exception{ > DocumentBuilder docbuilder = XMLParserUtils.getXMLDocBuilder(); > Document doc = docbuilder.newDocument(); > 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"); > } > } > > > > > Client: > > package altituderesponsatest; > public class AniSender { > > public void sendAni(URL serviceURL, String msgFilename) > throws IOException, SAXException, SOAPException { > > FileReader reader = new FileReader(msgFilename); > DocumentBuilder builder = XMLParserUtils.getXMLDocBuilder(); > Document doc = builder.parse(new InputSource(reader)); > if (doc == null) { > throw new SOAPException(Constants.FAULT_CODE_CLIENT, > "Error parsing XML message."); > } > Envelope msgEnvelope = > Envelope.unmarshall(doc.getDocumentElement()); > Message msg = new Message(); > msg.send(serviceURL, "urn:Processor", msgEnvelope); > SOAPTransport transport = msg.getSOAPTransport(); > BufferedReader resReader = transport.receive(); > String line; > while ((line = resReader.readLine()) != null) { > System.out.println(line); > } > } > > public static void main(String[] args) { > try { > URL serviceURL = > new > URL("http://localhost:8080/soap/servlet/messagerouter"); > AniSender aniSender = new AniSender(); > aniSender.sendAni(serviceURL, args[0]); > } catch (Exception e) { > e.printStackTrace(); > } > } > > } > > I would be most grateful for any input > > Tony > > > >