AnsweredAssumed Answered

Mail Task Fails to Execute using Activiti Rest Service

Question asked by softcoder on Nov 13, 2014
Latest reply on Jun 15, 2016 by imsrk
I have a workflow that contains a mail task. Prior to adding the mail task, user tasks and service tasks have been executing well. Upon adding mail tasks, i get the exception added below.
My best guess is my mail conffiguration is wrong.
I have tried:
1- Creating a activiti-cfg.jar which contains activiti.cfg.xml with my appropriate mail config and putting it in my tomcat/lib and build path of the activiti-rest app. Doesn't work.
2- Creating file in my class path with appropriate mail config. Doesn't work.
3- Creating activiti-standalone-context.xml contaning the mail config in rest and explorer app. Doesn't work.
4- Putting activiti.cfg.xml in the build path of my explorer and rest app. Doesn't work.

I am using Activiti v5.16.4.
Any Suggestions?

SEVERE: Servlet.service() for servlet [dispatcher] in context with path [/activiti-rest] threw exception [Request processing failed; nested exception is org.activiti.engine.ActivitiException: Could not send e-mail in execution 102529] with root cause Connection refused: connect
   at Method)
   at Source)
   at Source)
   at Source)
   at Source)
   at Source)
   at Source)
   at Source)
   at Source)
   at com.sun.mail.util.SocketFetcher.createSocket(
   at com.sun.mail.util.SocketFetcher.getSocket(
   at com.sun.mail.smtp.SMTPTransport.openServer(
   at com.sun.mail.smtp.SMTPTransport.protocolConnect(
   at javax.mail.Service.connect(
   at javax.mail.Service.connect(
   at javax.mail.Service.connect(
   at javax.mail.Transport.send0(
   at javax.mail.Transport.send(
   at org.apache.commons.mail.Email.sendMimeMessage(
   at org.apache.commons.mail.Email.send(
   at org.activiti.engine.impl.bpmn.behavior.MailActivityBehavior.execute(
   at org.activiti.engine.impl.pvm.runtime.AtomicOperationActivityExecute.execute(