Hi all,
I am using alfresco community version 5.2. I am using the Discussions feature provided by alfresco. I have set e-mail settings using the configuration in global properties:
##SMTP Configuration##
mail.host=smtp.gmail.com
mail.port=465
mail.username=rRajandaddu@gmail.com
mail.password=iamhuman@2367
mail.protocol=smtps
mail.smtps.starttls.enable=true
mail.smtps.auth=true
mail.from.default=rRajandaddu@gmail.com
mail.from.enabled=false
mail.encoding=UTF-8
mail.testmessage.send=true
mail.testmessage.to=rRajandaddu@gmail.com
mail.testmessage.subject=Inbound SMTP
mail.testmessage.text=Successfully implemented in Rajandaddu DMS.
But email is not notifying.
I am using the Discussions feature so i want mail notification should be send as any new topic is initiated to all involved in that discussion . And while replying to any others the reply should be notified in the mail whom anyone have replied.
As well as there is no option of attaching any documents with the topic .How to achieve this .
Regards
Akash D
Gmail does't allow to use smpt feature by default now and considers it as unsecure practice for the gmail account. However, if you are trying to use the gmail smtp, you need to enable it from your account's security settings.
In order to send email via gmail follow the steps below:
If you have already done these steps, check the server log and see if you can locate any errors.
You can also setup local smtp server (using Apache James/Hedwid/Fakesmtp etc.) if you are doing email functionality testing, refer the post below:
https://javaworld-abhinav.blogspot.com/2019/04/setting-up-local-mail-server-using.html
Thanks for the response.
But I have already done the gmail setting change. My objective is that I am using discussion feature and I want that when someone replies to someone's topic then they get notified by mail .So how to achieve that one .
Like A starts a discussion topic and tag B C and D . Now if B replies to A then A should get notified by a mail that B have commented like this . Is there any possible way to do it..
ok i thought you have implemented email notifications already and have problems with sending/receiving emails.
Alfresco Discussions feature doesn't have notification functionality by default as far as i know. You have to implement the functionality youself.
Quick hint:
As you know anything you create in alfresco is created as a node. This discussion functionality also has a model called forumModel
All Topics have a type (fm: topic) and all posts/replies (fm: post) also have a type under the hood. All fm: post are created as association to fm: topic using cm: contains child-association.
You can create a behavior which can listen to OnCreateNode / OnUpdateNode / OnCreateChildAssociation / OnContentUpdate events depending on your use case and get the modifier of node (userName) and use PersonService to find the email id of the user and notify using MailActionExecuter or create your custom email utility whichever suits your needs.
Also have a look at this add-on and see if it is useful: https://github.com/malariagen/alfresco-discussions
The alfresco discussions addon doesn't work properly as of 5.2 (ref https://hub.alfresco.com/t5/alfresco-content-services-forum/rules-not-working-after-upgrade/m-p/2941...), which also means the simple way of implementing this functionality won't work either.
As discussions are deprecated anyway I've no plans to fix it - we've moved our discussions to discourse instead - wasn't that hard to write a migration script
(I haven't tried it on later versions)
Inconvenient and a nail in the coffin of our Alfresco implementation but there you go...
Ask for and offer help to other Alfresco Content Services Users and members of the Alfresco team.
Related links:
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.