Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Why Class not found exception when using J2EE?

843830Aug 23 2005 — edited Nov 3 2008
I thought Java Mail was included with J2EE. If this is the case, why am I getting this exception when trying to send mail?

java.lang.NoClassDefFoundError: javax/mail/Authenticator
at org.apache.naming.factory.MailSessionFactory.getObjectInstance(MailSessionFactory.java:104)
at org.apache.naming.factory.ResourceFactory.getObjectInstance(ResourceFactory.java:129)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:304)
at org.apache.naming.NamingContext.lookup(NamingContext.java:792)
at org.apache.naming.NamingContext.lookup(NamingContext.java:139)
at org.apache.naming.NamingContext.lookup(NamingContext.java:780)
at org.apache.naming.NamingContext.lookup(NamingContext.java:152)
at com.r10.rp.servlets.TestMail.processRequest(TestMail.java:42)

The documentation states that the Activation.jar and mail.jar should not be needed with J2EE. I'm using J2EE 1.4 on Tomcat 5.5.

Thanks.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 1 2008
Added on Aug 23 2005
5 comments
2,955 views