cancel
Showing results for 
Search instead for 
Did you mean: 

Outbound SMTP in email subsystem

loftux
Star Contributor
Star Contributor
In sample configuration for alfresco-global.properties there is a setting for mail.smpt.auth, this is never taken into account since in the file
WEB-INF\classes\alfresco\subsystem\email\OutboundSMTP\outboundSMTP-context.xml
the key is define as mail.smtps.auth (note the additional s).

This has already been filed as a case by a "Cristian"
https://issues.alfresco.com/jira/browse/ALF-2688
Following this (changing to mail.smtp.auth in outboundSMTP-context.xml ), my smtp sending problems are resolved.

To fix this for 3.3 community, I wanted to create a subsystem override instead of editing default config file, and created
tomcat/shared/classes/alfresco/extension/subsystems/email/outbound/default/outboundSMTP-context.xml
(also tried tomcat/shared/classes/alfresco/extension/subsystems/email/OutboundSTMP/default/outboundSMTP-context.xml).
Property changes still in alfresco-global.properties.

Questions:
-Did I get the subsystems paths/override correctly? The new file doesn't get picked up.
-What is the proper javaMail key? mail.smtp.auth or mail.smtps.auth? Would it be possible to have both in outboundSMTP-context.xml, and depending of whether you want SSL or not set one or the other to true? I will amend any response I get here to the case.
2 REPLIES 2

trialot
Champ in-the-making
Champ in-the-making
Loftux,

Some remarks:

- mail.smtp.auth is the variable used by subetha mail program, just keep that in it.
- mail.smpts.auth is the secure smtp variant and concerns another item (relevant for gmail, for example)
- the subsystem email is not loading custom properties files…..indeed

So, my advice: do not change the context xml file (no need to).

However….you are still partly right, in the sense that the mail.smtp.auth is not used properly (it is indifferent between false/true). There is a bug, I presume.

Alfresco engineers, be more specific about the possibilities to create a subsytem override in "classes/alfresco/extension/subsystems" and make sure that this override is picked up!

Kind regards….

billerby
Champ on-the-rise
Champ on-the-rise
Since I had to do this now, I thought I could post the answer in case someone finds this thread when googling Smiley Happy

I'm extending the MailActionExecuter to be able to send attachments and had to redeclare this bean in the very same file. (outboundSMTP.context.xml).

To make the subsystem pick up the spring-config it had to be placed in the following extension path: "/alfresco/extension/subsystems/email/OutboundSMTP/outbound/custom-outboundSMTP-context.xml" The file could have any name with the *-context.xml extension.

/Erik