[ https://issues.apache.org/jira/browse/SYNCOPE-457?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13837633#comment-13837633 ]
Hadrian Zbarcea commented on SYNCOPE-457: ----------------------------------------- I was thinking about something along the same lines. It has the added advantage of not creating a new JavaMailSenderImpl instance for every send. What I am not yet sure about is if we need to have an SMTP host per sender. Can we have multiple/different senders? Still a noob on syncope :). > Must be able to configure JavaMailSender used by NotificationJob > ---------------------------------------------------------------- > > Key: SYNCOPE-457 > URL: https://issues.apache.org/jira/browse/SYNCOPE-457 > Project: Syncope > Issue Type: Bug > Components: core > Affects Versions: 1.1.5, 1.2.0 > Reporter: Hadrian Zbarcea > Assignee: Hadrian Zbarcea > Fix For: 1.2.0 > > > In NotificationJob.executeSingle we instantiate a new JavaMailSenderImpl() > which we then populate with some values. There are however other properties > [1] that can be set on the Session. Some of them are very useful, especially > in production environments. > In particular, the 'mail.smtp.connectiontimeout' should be set to a different > value than the default 'infinite' which would cause the thread to hang, > waiting for a unresponsive SMTP server (either misconfiguration of server > down). > I will try to come up with a patch towards the end of the week if nobody > beats me to it. > [1] https://javamail.java.net/nonav/docs/api/ -- This message was sent by Atlassian JIRA (v6.1#6144)