Email notifications from Confluence are duplicated using Microsoft Exchange Server
Platform notice: Server and Data Center only. This article only applies to Atlassian products on the server and data center platforms.
Problem
Duplicate emails are sent to people using remote Exchange servers; or mail stops being sent and are added to the Mail Queue.
The following error might appear in the atlassian-confluence.log:
ERROR [NotificationSender:thread-2] [plugin.notifications.dispatcher.NotificationErrorRegistryImpl] addError Error sending notification to server '<Unknown>'(-1) for INDIVIDUAL task (resent 4 times): Error sending to individual '8a818228609ba3ef01509ecd16fb0669' on server 'System Mail'
NotificationException: javax.mail.MessagingException: Exception reading response;
nested exception is:
java.net.SocketTimeoutException: Read timed out
......
Cause
Mail stops sending because the mail thread cannot connect to the server, and there is no timeout set.
Workarounds
Increase the SMTP Timeout
Increasing the SMTP Timeout will prevent Confluence from timing out too quickly and duplicating the messages. From How To Set the SMTP Timeout in Confluence:
Switch to a JNDI Connector
If a JNDI Connector is configured in Tomcat, there is no timeout value set and it defaults to -1 which is unlimited. This will prevent Confluence from timing out too quickly and duplicating the messages. From Connect Exchange Server To Confluence via JNDI: