Matt Matt - 1 month ago 16
Java Question

JavaMail and Java 1.4 - Logger not found

I'm trying to use JavaMail API 1.4.6 in my project which uses Java 1.4 (required).
I'm getting error:

[stderr] java.lang.NoClassDefFoundError: java.util.logging.Logger
[stderr] at com.sun.mail.util.MailLogger.<init>(MailLogger.java:104)
[stderr] at javax.mail.Session.initLogger(Session.java:227)
[stderr] at javax.mail.Session.<init>(Session.java:212)
[stderr] at javax.mail.Session.getDefaultInstance(Session.java:315)


Where can I download the old java libraries to include in my project? I have only Java 1.7 installed on my Windows 8 PC.

Is it possible to use a different Logger library here, or try and older JavaMail API version?

Answer

You mention in this comment that you're using the JRE on an embedded device (Ricoh printer). If you're referring to Ricoh's ESA then this claims to be J2ME, not J2SE. J2ME includes some but not all the standard J2SE classes, and java.util.logging appears to be one of those packages that is not included.

Comments