Howdy,
Why are you using such an old xerces?  Most apps, including tomcat and
every recent SOAP handler (recent = a year at least) require a JAXP 1.1
compliant parser.

>From a clean install of tomcat 4.1, I've never had a problem using
Apache Axis, MindElectric GLUE, or the SOAP APIs that come with the Sun
Java Web Service Development Kit, but I've always used JDK 1.4 and its
parsers (or later parsers, never earlier).

Yoav Shapira
Millennium ChemInformatics


>-----Original Message-----
>From: Clive Jordan [mailto:[EMAIL PROTECTED]
>Sent: Tuesday, December 09, 2003 12:18 PM
>To: [EMAIL PROTECTED]
>Subject: Apache SOAP Messaging Error (org.apache.soap.Envelope)
>
>Hello,
>
>I am having a lot of difficulty getting apache SOAP messaging to work
>properly. It does not seem to be  able to find
org.soap.apache.Envelope
>for some reason.
>
>Sorry for  the  large amount of spam but I thought I'd  put down as
much
>info as possible.
>
>My environment is:
>Windows 2000
>jsdk 1.4.1_01
>Tomcat 4.1.29
>SOAP 2.3.1
>Xerces 1.4.4
>
>Backgroud:
>I have been through the archives and seen there are problems with
>classloaders in the past and I have tried the following:
>
>Clean install of Tomcat 4.1.29
>put soap.war in webapps and restart.
>the .war file is unpacked ok.
>
>I have looked through these
>http://nagoya.apache.org/eyebrowse/ReadMsg?listName=tomcat-
>[EMAIL PROTECTED]&msgNo=32379
>
>
>and tried the following:
>- removed xerces2 files from distribution and put Xerces 1.4.4
>xerces.jar in $CATALINA_HOME/common/lib
>- remove soap.war from webapps
>- removed org directory from webapps/soap/WEB-INF/classes
>- put soap.jar into $CATALINA_HOME/common/lib
>
>My command-line classpath (for client use):
>c:\bin\Tomcat4.1\common\lib\xerces.jar;c:\bin\j2sdk1.4.1_01;c:\bin\Tomc
at4.
>1\common\lib\servlet.jar;c:\bin\Tomcat4.1\common\lib\soap.jar;c:\bin\To
mcat
>4.1\common\lib\mail.jar;c:\bin\Tomcat4.1\common\lib\activation.jar;.
>
>As you can see, all the appropriate classes are in the tomcat tree.
>
>Here is my processing class, TstSoap.java:
>import java.io.*;
>import org.apache.soap.*;
>import org.apache.soap.rpc.SOAPContext;
>import javax.mail.MessagingException;
>
>public class TstSoap
>{
>    public void tstMethod (Envelope env, SOAPContext reqCtx,
SOAPContext
>resCtx)
>                            throws MessagingException, IOException
>    {
>        resCtx.setRootPart("OK it works.", "text/xml");
>    }
>}
>
>Here is the Deployment Descriptor, DeploymentDescriptor.xml:
><isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment";
>             id="urn:soaptest" type="message">
>  <isd:provider type="java"
>                scope="Application"
>                methods="tstMethod">
>    <isd:java class="TstSoap" static="false"/>
>  </isd:provider>
>
>
><isd:faultListener>org.apache.soap.server.DOMFaultListener</isd:faultLi
sten
>er>
></isd:service>
>
>And finally, here is the SOAP message that is sent:
><SOAP-ENV:Envelope
>xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/";
>    SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/";>
>    <SOAP-ENV:Body>
>        <tstMethod xmlns="urn:soaptest" >
>        </tstMethod>
>    </SOAP-ENV:Body>
></SOAP-ENV:Envelope>
>
>All  three of the above are in the directory
>c:/bin/cygwin/home/clive/src/woko on my computer.
>
>-Within catalina.sh, I have added this to the classpath of the server:
>CLASSPATH="$CLASSPATH":"$CATALINA_HOME"../../cygwin/home/clive/src/woko
>
>Then I start the server:
>startup.sh
>
>Next I register the DeploymentDescriptor from the woko directory:
>java org.apache.soap.server.ServiceManagerClient
>http://localhost:8080/soap/servlet/rpcrouter deploy
>DeploymentDescriptor.xml
>
>This seems to work ok as I can then see if it is registered with
tomcat:
>java org.apache.soap.server.ServiceManagerClient
>http://localhost:8080/soap/servlet/rpcrouter list
>
>gives:
>Deployed Services:
>        urn:soaptest
>
>Now I send the xml message to the messagerouter (where msg1.xml is the
>aml message above):
>java SOAPClient4XG http://localhost:8080/soap/servlet/messagerouter
>msg1.xml
>
>And (finally), this is what I get back:
>java.io.IOException: Server returned HTTP response code: 500 for URL:
>http://localhost:8080/soap/servlet/messagerouter
>        at
>sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source)
>        at SOAPClient4XG.main(SOAPClient4XG.java:72)
>Exception in thread "main"
>
>Not that useful :-(
>If instead I start the apache TunnelGui on port 4040, and try again,
>this is what I get. (Note the line I have changed to bold)
>HTTP/1.1 500 Internal Server Error
>Set-Cookie: JSESSIONID=84720BCEC2C28DD4AEDF25B02B4B3207; Path=/soap
>Content-Type: text/xml;charset=utf-8
>Content-Length: 4066
>Date: Tue, 09 Dec 2003 17:05:15 GMT
>Server: Apache-Coyote/1.1
>Connection: close
>
><?xml version='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</faultcode>
><faultstring>Exception while handling service request:
>org/apache/soap/Envelope</faultstring>
><faultactor>/soap/servlet/messagerouter</faultactor>
><detail>
><stackTrace>java.lang.NoClassDefFoundError: org/apache/soap/Envelope
>    at java.lang.Class.getDeclaredMethods0(Native Method)
>.... lots of java errors......
>
>
>So why can't the system find this:
>java.lang.NoClassDefFoundError: org/apache/soap/Envelope
>
>Poking into the soap.jar library in common/lib and it is there ok.
>*Please*, does anyone know what I am doing wrong here, I really am
>rather stumped :-(
>
>If I explicitly put soap.jar on the server classpath, I cannot deploy
>servlets and get web pages returned rather than XML and the parser does
>not like that (I won't put this in the email as I'm sure I've used
>enough space already).
>
>So, does anyone know if (1) I am being stupid or (2) is there a fault
or
>issue/workaround I should know about.
>
>Would really appreciate some help with this.
>
>Thanks,
>Clive
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to