No email functionality

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-16-2015 02:38 PM
Hi,
Am running Alfresco Community 5.0.d and am executing a rule that emails a recipient when new content is added to a folder. I have tried Perform Action: Send Email from the list of Rule Actions, as well as this script:
function sendMail()
{
var mail = actions.create("mail");
mail.parameters.to = clenig@bomarko.com["cm:email"];
mail.parameters.subject = "Supplier Assessment Alert";
mail.parameters.from = "Docmanagementsystem@gmail.com";
mail.parameters.template = companyHome.childByNamePath("Data Dictionary/Email Templates/assessment_notification_email.html.ftl");
mail.parameters.text = "A new Supplier Assessment (BO-13) form has been submitted.";
}
// execute action against a document
mail.execute(document);
}
sendMail();
My alfresco-global.properties file has these parameters:
mail.host=smtp.gmail.com
mail.port=465
mail.username=Docmanagementsystem@gmail.com
mail.password=B0m@rk0
mail.protocol=smtps
mail.smtps.starttls.enable=true
mail.smtps.auth=true
mail.smtp.debug=false
mail.smtp.timeout=30000
mail.from.default=Docmanagementsystem@gmail.com
No one receives any email when I upload a file using Perform Action: Send Email. Even if I create a site and invite a user, the invite appears as a task on their dashboard - no email generated.
When new content is uploaded to the folder and I use the javascript above, I get the error (Failure: Failed to execute script 'workspace://SpacesStore/9910b10a-33cc-42d4-a142-08c9efaad4ee': syntax error (workspace://SpacesStore/9910b10a-33cc-42d4-a142-08c9efaad4ee#13)) and the upload is cancelled.
Using the command prompt and mail -s "Text" clenig@bomarko.com <messagefile.txt, I am able to send an email from the computer which is hosting Alfresco.
Can anyone please offer insight into why my Alfresco is not creating emails?
Thank you in advance,
Frank
Am running Alfresco Community 5.0.d and am executing a rule that emails a recipient when new content is added to a folder. I have tried Perform Action: Send Email from the list of Rule Actions, as well as this script:
function sendMail()
{
var mail = actions.create("mail");
mail.parameters.to = clenig@bomarko.com["cm:email"];
mail.parameters.subject = "Supplier Assessment Alert";
mail.parameters.from = "Docmanagementsystem@gmail.com";
mail.parameters.template = companyHome.childByNamePath("Data Dictionary/Email Templates/assessment_notification_email.html.ftl");
mail.parameters.text = "A new Supplier Assessment (BO-13) form has been submitted.";
}
// execute action against a document
mail.execute(document);
}
sendMail();
My alfresco-global.properties file has these parameters:
mail.host=smtp.gmail.com
mail.port=465
mail.username=Docmanagementsystem@gmail.com
mail.password=B0m@rk0
mail.protocol=smtps
mail.smtps.starttls.enable=true
mail.smtps.auth=true
mail.smtp.debug=false
mail.smtp.timeout=30000
mail.from.default=Docmanagementsystem@gmail.com
No one receives any email when I upload a file using Perform Action: Send Email. Even if I create a site and invite a user, the invite appears as a task on their dashboard - no email generated.
When new content is uploaded to the folder and I use the javascript above, I get the error (Failure: Failed to execute script 'workspace://SpacesStore/9910b10a-33cc-42d4-a142-08c9efaad4ee': syntax error (workspace://SpacesStore/9910b10a-33cc-42d4-a142-08c9efaad4ee#13)) and the upload is cancelled.
Using the command prompt and mail -s "Text" clenig@bomarko.com <messagefile.txt, I am able to send an email from the computer which is hosting Alfresco.
Can anyone please offer insight into why my Alfresco is not creating emails?
Thank you in advance,
Frank
Labels:
- Labels:
-
Archive
5 REPLIES 5
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-19-2015 12:09 PM
There's probably an error recorded in your alfresco.log find it.
Then its likely to either be gmail security (perhaps requiring you to log on via the web first) or another error.
I cant see an error in your java script.
Then its likely to either be gmail security (perhaps requiring you to log on via the web first) or another error.
I cant see an error in your java script.

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-21-2015 07:42 AM
Thank you for reviewing the script. At least I know the problem isn't there.
Checked the alfresco log as per your recommendation. The email function in Alfresco is continuing to attempt to send every email it has been presented with in the past week.
Log excerpt is below (I already corrected the double .com entry in my admin email address, which only applied to my profile, so that's not the problem). The problem seems to be with authentication. I tried a Gmail account, which requires authentication, AND my employer's hosted email service, which does not require authentication, to be enabled and BOTH scenarios yielded the same errors.
[org.alfresco.repo.action.executer.MailActionExecuter] [FeedNotifier1] Failed to send email to fromano@bomarko.com.com : org.springframework.mail.MailAuthenticationException: Authentication failed; nested exception is javax.mail.AuthenticationFailedException: No authentication mechanisms supported by both server and client
2015-10-19 00:00:00,314 WARN [org.alfresco.repo.activities.feed.FeedNotifier] [FeedNotifier1] FeedNotifier: Failed to process entry "Person admin".
org.alfresco.error.AlfrescoRuntimeException: 09198893 Failed to send email to:fromano@bomarko.com.com
at org.alfresco.repo.action.executer.MailActionExecuter.sendEmail(MailActionExecuter.java:1070)
at org.alfresco.repo.action.executer.MailActionExecuter.executeImpl(MailActionExecuter.java:517)
at org.alfresco.repo.action.executer.ActionExecuterAbstractBase.execute(ActionExecuterAbstractBase.java:265)
at sun.reflect.GeneratedMethodAccessor1449.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at org.alfresco.repo.management.subsystems.SubsystemProxyFactory$1.invoke(SubsystemProxyFactory.java:72)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at com.sun.proxy.$Proxy314.execute(Unknown Source)
at org.alfresco.repo.action.ActionServiceImpl.directActionExecution(ActionServiceImpl.java:839)
at org.alfresco.repo.action.ActionServiceImpl.executeActionImpl(ActionServiceImpl.java:739)
at org.alfresco.repo.action.ActionServiceImpl.executeAction(ActionServiceImpl.java:573)
at org.alfresco.repo.action.ActionServiceImpl.executeAction(ActionServiceImpl.java:559)
at org.alfresco.repo.action.ActionServiceImpl.executeAction(ActionServiceImpl.java:848)
at sun.reflect.GeneratedMethodAccessor1522.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.alfresco.repo.security.permissions.impl.AlwaysProceedMethodInterceptor.invoke(AlwaysProceedMethodInterceptor.java:34)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.alfresco.repo.security.permissions.impl.ExceptionTranslatorMethodInterceptor.invoke(ExceptionTranslatorMethodInterceptor.java:46)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.alfresco.repo.audit.AuditMethodInterceptor.invoke(AuditMethodInterceptor.java:159)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:96)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:260)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:94)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at com.sun.proxy.$Proxy64.executeAction(Unknown Source)
at org.alfresco.repo.activities.feed.EmailUserNotifier.notifyUser(EmailUserNotifier.java:180)
at org.alfresco.repo.activities.feed.AbstractUserNotifier.notifyUser(AbstractUserNotifier.java:221)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2.processInternal(FeedNotifierImpl.java:385)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2.access$100(FeedNotifierImpl.java:339)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2$1$1.execute(FeedNotifierImpl.java:371)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2$1$1.execute(FeedNotifierImpl.java:368)
at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:457)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2$1.doWork(FeedNotifierImpl.java:367)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2$1.doWork(FeedNotifierImpl.java:363)
at org.alfresco.repo.tenant.TenantUtil.runAsWork(TenantUtil.java:119)
at org.alfresco.repo.tenant.TenantUtil.runAsTenant(TenantUtil.java:88)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2.process(FeedNotifierImpl.java:362)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2.process(FeedNotifierImpl.java:339)
at org.alfresco.repo.batch.BatchProcessor$TxnCallback.execute(BatchProcessor.java:713)
at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:457)
at org.alfresco.repo.batch.BatchProcessor$TxnCallback.run(BatchProcessor.java:757)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Any guidance is appreciated,
Frank
Checked the alfresco log as per your recommendation. The email function in Alfresco is continuing to attempt to send every email it has been presented with in the past week.
Log excerpt is below (I already corrected the double .com entry in my admin email address, which only applied to my profile, so that's not the problem). The problem seems to be with authentication. I tried a Gmail account, which requires authentication, AND my employer's hosted email service, which does not require authentication, to be enabled and BOTH scenarios yielded the same errors.
[org.alfresco.repo.action.executer.MailActionExecuter] [FeedNotifier1] Failed to send email to fromano@bomarko.com.com : org.springframework.mail.MailAuthenticationException: Authentication failed; nested exception is javax.mail.AuthenticationFailedException: No authentication mechanisms supported by both server and client
2015-10-19 00:00:00,314 WARN [org.alfresco.repo.activities.feed.FeedNotifier] [FeedNotifier1] FeedNotifier: Failed to process entry "Person admin".
org.alfresco.error.AlfrescoRuntimeException: 09198893 Failed to send email to:fromano@bomarko.com.com
at org.alfresco.repo.action.executer.MailActionExecuter.sendEmail(MailActionExecuter.java:1070)
at org.alfresco.repo.action.executer.MailActionExecuter.executeImpl(MailActionExecuter.java:517)
at org.alfresco.repo.action.executer.ActionExecuterAbstractBase.execute(ActionExecuterAbstractBase.java:265)
at sun.reflect.GeneratedMethodAccessor1449.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at org.alfresco.repo.management.subsystems.SubsystemProxyFactory$1.invoke(SubsystemProxyFactory.java:72)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at com.sun.proxy.$Proxy314.execute(Unknown Source)
at org.alfresco.repo.action.ActionServiceImpl.directActionExecution(ActionServiceImpl.java:839)
at org.alfresco.repo.action.ActionServiceImpl.executeActionImpl(ActionServiceImpl.java:739)
at org.alfresco.repo.action.ActionServiceImpl.executeAction(ActionServiceImpl.java:573)
at org.alfresco.repo.action.ActionServiceImpl.executeAction(ActionServiceImpl.java:559)
at org.alfresco.repo.action.ActionServiceImpl.executeAction(ActionServiceImpl.java:848)
at sun.reflect.GeneratedMethodAccessor1522.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.alfresco.repo.security.permissions.impl.AlwaysProceedMethodInterceptor.invoke(AlwaysProceedMethodInterceptor.java:34)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.alfresco.repo.security.permissions.impl.ExceptionTranslatorMethodInterceptor.invoke(ExceptionTranslatorMethodInterceptor.java:46)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.alfresco.repo.audit.AuditMethodInterceptor.invoke(AuditMethodInterceptor.java:159)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:96)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:260)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:94)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at com.sun.proxy.$Proxy64.executeAction(Unknown Source)
at org.alfresco.repo.activities.feed.EmailUserNotifier.notifyUser(EmailUserNotifier.java:180)
at org.alfresco.repo.activities.feed.AbstractUserNotifier.notifyUser(AbstractUserNotifier.java:221)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2.processInternal(FeedNotifierImpl.java:385)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2.access$100(FeedNotifierImpl.java:339)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2$1$1.execute(FeedNotifierImpl.java:371)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2$1$1.execute(FeedNotifierImpl.java:368)
at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:457)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2$1.doWork(FeedNotifierImpl.java:367)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2$1.doWork(FeedNotifierImpl.java:363)
at org.alfresco.repo.tenant.TenantUtil.runAsWork(TenantUtil.java:119)
at org.alfresco.repo.tenant.TenantUtil.runAsTenant(TenantUtil.java:88)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2.process(FeedNotifierImpl.java:362)
at org.alfresco.repo.activities.feed.FeedNotifierImpl$2.process(FeedNotifierImpl.java:339)
at org.alfresco.repo.batch.BatchProcessor$TxnCallback.execute(BatchProcessor.java:713)
at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:457)
at org.alfresco.repo.batch.BatchProcessor$TxnCallback.run(BatchProcessor.java:757)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Any guidance is appreciated,
Frank
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-21-2015 09:11 AM
You need to turn off authentication if it is not needed, that's probably the root cause of the exception you have posted above. You haven't said which settings go with the error message.

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-22-2015 03:34 PM
I'm using the settings below (taken from the wiki). According to everything I've found Gmail requires authentication.
GMAIL
Gmail (gmail.com) requires the use of SMTPS
This example shows how to configure two additional java mail properties directly to: <TOMCAT_HOME>/classes/alfresco-global.properties:
# Sample Gmail settings
mail.host=smtp.gmail.com
mail.port=465
mail.username=user@gmail.com
mail.password=password
mail.protocol=smtps
mail.smtps.starttls.enable=true
mail.smtps.auth=true
Frank
GMAIL
Gmail (gmail.com) requires the use of SMTPS
This example shows how to configure two additional java mail properties directly to: <TOMCAT_HOME>/classes/alfresco-global.properties:
# Sample Gmail settings
mail.host=smtp.gmail.com
mail.port=465
mail.username=user@gmail.com
mail.password=password
mail.protocol=smtps
mail.smtps.starttls.enable=true
mail.smtps.auth=true
Frank

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-22-2015 03:57 PM
Also, if I telnet into my host on port 25, the response states all is well
