Re: More java.lang.NoClassDefFoundError
If Tomcat needs the classes at runtime, then they should be under CATALINA_HOME. If you need those same classes at compile time, then the CLASSPATH should be updated to point to the location under CATALINA_HOME where the classes reside. John On Fri, 11 Jul 2003 20:03:03 -0700, [EMAIL PROTECTED] wrote: OK, I'm going a little (more) crazy here. I *think* that the problem might be that the mail stuff is the very first use I've made of a J2EE component. The code is compiled with a CLASSPATH which includes x:\usr\local\j2ee\j2ee.jar. The standalone code runs fine, and presumably at runtime it finds the same j2ee.jar and that includes javax.mail.* When I first started having problems I think that they were ClassNotFound, and I was advised to put mail.jar into TOMCAT_HOME\lib. I found a copy and did that. However, mail.jar is (I think) older than j2ee.jar (the classes are probably different anyway), and contains (some) of the same classes as j2ee.jar. If the above is correct, where should the j2ee.jar file go? And once I move it, I should update the CLASSPATH to point to the same spot, right? Regards, Terry Fuller [EMAIL PROTECTED] --- In [EMAIL PROTECTED], on 07/11/2003 at 12:51 PM, John Turner [EMAIL PROTECTED] said: It means that the class you told your servlet to use is not the class that it is actually finding. Typically, this means that you have more than one copy of a JAR file (like servlet.jar) in Tomcat's ClassLoader path, and Tomcat is telling you that it doesn't know which one to use. John On Thu, 10 Jul 2003 22:09:01 -0700, [EMAIL PROTECTED] wrote: Well, I'm back again for some help. I'm running Java 1.3.1, Tomcat 3.3.1 I have a small proof of concept java program which uses javax.mail and which successfully sends off a note. When I incorporate the proof of concept code into a servlet, I get: java.lang.NoClassDefFoundError: javax/activation/DataSource What am I missing that the straight Java code runs but the servlet can't seem to find the parts used by the proof code? Is there a general approach for dealing with NoClassDef errors? I know that the message indicates something other than ClassNotFound, but what really does it mean? Pointers to existing doc gratefully received. Thanks! Regards, Terry Fuller [EMAIL PROTECTED] --- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: More java.lang.NoClassDefFoundError
It means that the class you told your servlet to use is not the class that it is actually finding. Typically, this means that you have more than one copy of a JAR file (like servlet.jar) in Tomcat's ClassLoader path, and Tomcat is telling you that it doesn't know which one to use. John On Thu, 10 Jul 2003 22:09:01 -0700, [EMAIL PROTECTED] wrote: Well, I'm back again for some help. I'm running Java 1.3.1, Tomcat 3.3.1 I have a small proof of concept java program which uses javax.mail and which successfully sends off a note. When I incorporate the proof of concept code into a servlet, I get: java.lang.NoClassDefFoundError: javax/activation/DataSource What am I missing that the straight Java code runs but the servlet can't seem to find the parts used by the proof code? Is there a general approach for dealing with NoClassDef errors? I know that the message indicates something other than ClassNotFound, but what really does it mean? Pointers to existing doc gratefully received. Thanks! Regards, Terry Fuller [EMAIL PROTECTED] --- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: More java.lang.NoClassDefFoundError
OK, I'm going a little (more) crazy here. I *think* that the problem might be that the mail stuff is the very first use I've made of a J2EE component. The code is compiled with a CLASSPATH which includes x:\usr\local\j2ee\j2ee.jar. The standalone code runs fine, and presumably at runtime it finds the same j2ee.jar and that includes javax.mail.* When I first started having problems I think that they were ClassNotFound, and I was advised to put mail.jar into TOMCAT_HOME\lib. I found a copy and did that. However, mail.jar is (I think) older than j2ee.jar (the classes are probably different anyway), and contains (some) of the same classes as j2ee.jar. If the above is correct, where should the j2ee.jar file go? And once I move it, I should update the CLASSPATH to point to the same spot, right? Regards, Terry Fuller [EMAIL PROTECTED] --- In [EMAIL PROTECTED], on 07/11/2003 at 12:51 PM, John Turner [EMAIL PROTECTED] said: It means that the class you told your servlet to use is not the class that it is actually finding. Typically, this means that you have more than one copy of a JAR file (like servlet.jar) in Tomcat's ClassLoader path, and Tomcat is telling you that it doesn't know which one to use. John On Thu, 10 Jul 2003 22:09:01 -0700, [EMAIL PROTECTED] wrote: Well, I'm back again for some help. I'm running Java 1.3.1, Tomcat 3.3.1 I have a small proof of concept java program which uses javax.mail and which successfully sends off a note. When I incorporate the proof of concept code into a servlet, I get: java.lang.NoClassDefFoundError: javax/activation/DataSource What am I missing that the straight Java code runs but the servlet can't seem to find the parts used by the proof code? Is there a general approach for dealing with NoClassDef errors? I know that the message indicates something other than ClassNotFound, but what really does it mean? Pointers to existing doc gratefully received. Thanks! Regards, Terry Fuller [EMAIL PROTECTED] --- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
More java.lang.NoClassDefFoundError
Well, I'm back again for some help. I'm running Java 1.3.1, Tomcat 3.3.1 I have a small proof of concept java program which uses javax.mail and which successfully sends off a note. When I incorporate the proof of concept code into a servlet, I get: java.lang.NoClassDefFoundError: javax/activation/DataSource What am I missing that the straight Java code runs but the servlet can't seem to find the parts used by the proof code? Is there a general approach for dealing with NoClassDef errors? I know that the message indicates something other than ClassNotFound, but what really does it mean? Pointers to existing doc gratefully received. Thanks! Regards, Terry Fuller [EMAIL PROTECTED] --- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]