0
Not a bug

Email Notifications don't work

Udhay 8 years ago updated by Nguyen 8 years ago 11

No matter which smtp server (gmail,yahoo,custom) i use. I always get the below Error.

"We can not connect to the SMTP server. The root cause is org.apache.commons.mail.EmailException: Sending the email to the following server failed : smtp.mail.yahoo.com:465. Save the configuration anyway?"


Help!!

Not a bug

I have tested with yahoo, and it works. You should check the ssl option as well. This version seems to have a bug reported at http://mycollab.userecho.com/topics/115-mycollab-doesnt-send-notification-emails-but-test-email-works/. After changing the email, you should restart the server


Hai Nguyen


Im getting the below Exception............what should I DO?


09:32:00,866 ERROR c.m.s.j.ProjectSendingRelayEmailNotificationJob:50 - Error while sending scheduler command

com.mycollab.core.MyCollabException: org.apache.commons.mail.EmailException: Sending the email to the following server failed : smtp.mail.yahoo.com:465
at com.mycollab.module.mail.DefaultMailer.sendHTMLMail(DefaultMailer.java:107)
at com.mycollab.module.mail.DefaultMailer.sendHTMLMail(DefaultMailer.java:117)
at com.mycollab.module.mail.service.impl.ExtMailServiceImpl.sendHTMLMail(ExtMailServiceImpl.java:57)
at com.mycollab.module.project.schedule.email.service.SendMailToFollowersAction$$anonfun$sendNotificationForCommentAction$1.apply(SendMailToFollowersAction.scala:151)
at com.mycollab.module.project.schedule.email.service.SendMailToFollowersAction$$anonfun$sendNotificationForCommentAction$1.apply(SendMailToFollowersAction.scala:139)
at scala.collection.immutable.Set$Set2.foreach(Set.scala:128)
at com.mycollab.module.project.schedule.email.service.SendMailToFollowersAction.sendNotificationForCommentAction(SendMailToFollowersAction.scala:139)
at com.mycollab.schedule.jobs.ProjectSendingRelayEmailNotificationJob$$anonfun$executeJob$1.apply(ProjectSendingRelayEmailNotificationJob.scala:58)
at com.mycollab.schedule.jobs.ProjectSendingRelayEmailNotificationJob$$anonfun$executeJob$1.apply(ProjectSendingRelayEmailNotificationJob.scala:49)
at scala.collection.immutable.List.foreach(List.scala:381)
at com.mycollab.schedule.jobs.ProjectSendingRelayEmailNotificationJob.executeJob(ProjectSendingRelayEmailNotificationJob.scala:49)
at com.mycollab.schedule.jobs.GenericQuartzJobBean.executeInternal(GenericQuartzJobBean.scala:34)
at org.springframework.scheduling.quartz.QuartzJobBean.execute(QuartzJobBean.java:75)
at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573)
Caused by: org.apache.commons.mail.EmailException: Sending the email to the following server failed : smtp.mail.yahoo.com:465
at org.apache.commons.mail.Email.sendMimeMessage(Email.java:1421)
at org.apache.commons.mail.Email.send(Email.java:1448)
at com.mycollab.module.mail.DefaultMailer.sendHTMLMail(DefaultMailer.java:105)
... 14 common frames omitted
Caused by: javax.mail.MessagingException: Could not connect to SMTP host: smtp.mail.yahoo.com, port: 465
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:2120)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:712)
at javax.mail.Service.connect(Service.java:388)
at javax.mail.Service.connect(Service.java:246)
at javax.mail.Service.connect(Service.java:195)
at javax.mail.Transport.send0(Transport.java:254)
at javax.mail.Transport.send(Transport.java:124)
at org.apache.commons.mail.Email.sendMimeMessage(Email.java:1411)
... 16 common frames omitted
Caused by: javax.net.ssl.SSLException: java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty
at sun.security.ssl.Alerts.getSSLException(Alerts.java:208)
at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1949)
at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1906)
at sun.security.ssl.SSLSocketImpl.handleException(SSLSocketImpl.java:1889)
at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1410)
at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1387)
at com.sun.mail.util.SocketFetcher.configureSSLSocket(SocketFetcher.java:598)
at com.sun.mail.util.SocketFetcher.createSocket(SocketFetcher.java:372)
at com.sun.mail.util.SocketFetcher.getSocket(SocketFetcher.java:217)
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:2084)
... 23 common frames omitted
Caused by: java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty
at sun.security.validator.PKIXValidator.<init>(PKIXValidator.java:90)
at sun.security.validator.Validator.getInstance(Validator.java:179)
at sun.security.ssl.X509TrustManagerImpl.getValidator(X509TrustManagerImpl.java:312)
at sun.security.ssl.X509TrustManagerImpl.checkTrustedInit(X509TrustManagerImpl.java:171)
at sun.security.ssl.X509TrustManagerImpl.checkTrusted(X509TrustManagerImpl.java:184)
at sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:124)
at sun.security.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1491)
at sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:216)
at sun.security.ssl.Handshaker.processLoop(Handshaker.java:979)
at sun.security.ssl.Handshaker.process_record(Handshaker.java:914)
at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1062)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1375)
at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1403)
... 28 common frames omitted
Caused by: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty
at java.security.cert.PKIXParameters.setTrustAnchors(PKIXParameters.java:200)
at java.security.cert.PKIXParameters.<init>(PKIXParameters.java:120)
at java.security.cert.PKIXBuilderParameters.<init>(PKIXBuilderParameters.java:104)
at sun.security.validator.PKIXValidator.<init>(PKIXValidator.java:88)
... 40 common frames omitted


sudo update-ca-certificates -f ------------ didnt work


sudo apt-get install --reinstall ca-certificates-java ---------- didnt work

What is the java version you are using? also is it the openjdk or oracle java?

OpenJDK 64-Bit Server VM (build 25.91-b14, mixed mode)

I think so. See the trace, it is not the issue of MyCollab. Actually, we can send the email with yahoo on both Windows, and MacOS so I guess it depends on the system environment, may be the handshake of Java and Yahoo via SSL certificate. Could you try to use the Gmail account if you have on? We never see any issue with Gmail or Hotmail account so far.

Sure. Will try with gmail.

Let update me the status if you have the result :)

Its the same with Gmail as well. Im gonna remove openjdk and use oracle jdk and lets see what happens.

Yes, it is a good choice.