Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Scout » ImapAdapter(new ImapAdapter() throws ClassNotFoundException for AuthenticationFailedException)
ImapAdapter [message #1137133] Mon, 14 October 2013 09:27 Go to next message
Shawn Muller is currently offline Shawn MullerFriend
Messages: 3
Registered: October 2013
Junior Member
Hi

I am implementing IMAP into my scout project. I am following the step by step guide. However, when I call Mailservice.CreateImapAdapter() I run into some problems.

The line ImapAdapter myAdapter = new ImapAdapter(); throws the following exception
java.lang.ClassNotFoundException: javax.mail.AuthenticationFailedException cannot be found by org.eclipse.scout.rt.server_3.9.0.20130527-1025

I initially thought it was a an authentication issue, but on closer inspection it happens as soon as I call new ImapAdapter(). Interestingly, I can call AuthenticationFailedException x = new AuthenticationFailedException(); without problems. So it seems that I can load the javax.mail.AuthenticationFailedException

I am using eclipse kepler for scout v3.9.0
The javamail it is trying to load (I think) is javax.mail_1.4.0.v201005080615

Any ideas what the problem could be?

Regards
Shawn
Re: ImapAdapter [message #1137520 is a reply to message #1137133] Mon, 14 October 2013 14:56 Go to previous messageGo to next message
Jeremie Bresson is currently offline Jeremie BressonFriend
Messages: 1252
Registered: October 2011
Senior Member
I think those classes use an "Endorsed Java Mail".

I can recommend you to read:
* IMAP Step-by-Step tutorial.
* Java setup for Scout Commiter

Let us know if this helps or if you need more information...
Re: ImapAdapter [message #1138566 is a reply to message #1137520] Tue, 15 October 2013 07:04 Go to previous message
Shawn Muller is currently offline Shawn MullerFriend
Messages: 3
Registered: October 2013
Junior Member
I didn't previously specifically add mail.jar to the installed JRE in eclipse. I added the jar to the jre/lib directory only. I can now successfully connect to the mail server. However, I briefly ran into another problem.

ProcessingException[ProcessingStatus[ERROR code=0 invoking ch.pdg.webamis.shared.services.IMailService:getChildFolders / javax/mail/Store java.lang.LinkageError: javax/mail/Store]]

Caused by: java.lang.LinkageError: loader constraint violation: loader (instance of org/eclipse/osgi/internal/baseadaptor/DefaultClassLoader) previously initiated loading for a different type with name "javax/mail/Store"

This I resolved by removing javax.mail from the server manifest.

All working now. Thanks for the help

Previous Topic:JasperReport Dependencies
Next Topic:Deprecated HttpServiceTunnel
Goto Forum:
  


Current Time: Tue Mar 19 04:01:39 GMT 2024

Powered by FUDForum. Page generated in 0.01933 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top