public class AlfrescoJavaMailSender
extends org.springframework.mail.javamail.JavaMailSenderImpl
JavaMailSenderImpl to pool the Transports used to send emails.
This is to overcome problems reported in CLOUD-313.| Constructor and Description |
|---|
AlfrescoJavaMailSender() |
| Modifier and Type | Method and Description |
|---|---|
protected javax.mail.Transport |
getTransport(javax.mail.Session session) |
void |
setMaxActive(int maxActive)
Set the maximum number of active transports, managed by the pool.
|
void |
setMaxIdle(int maxIdle)
Set the maximum number of transports that can sit idle in the pool.
|
void |
setMaxWait(long maxWait)
Set the maximum amount of time (in milliseconds) to wait for a transport to be returned from the pool.
|
void |
setMinEvictableIdleTime(long time)
Set the minimum amount of time a transport may sit idle, before it is eligible for eviction.
|
void |
setPassword(String password) |
void |
setTimeBetweenEvictionRuns(long time)
Set the time (in milliseconds) between runs of the idle object eviction thread.
|
void |
setUsername(String userName) |
connectTransport, createMimeMessage, createMimeMessage, doSend, getDefaultEncoding, getDefaultFileTypeMap, getHost, getJavaMailProperties, getPassword, getPort, getProtocol, getSession, getUsername, send, send, send, send, send, send, setDefaultEncoding, setDefaultFileTypeMap, setHost, setJavaMailProperties, setPort, setProtocol, setSession, testConnectionprotected javax.mail.Transport getTransport(javax.mail.Session session)
throws javax.mail.NoSuchProviderException
getTransport in class org.springframework.mail.javamail.JavaMailSenderImplPooledTransportWrapper which borrows a pooled Transport on connect, and returns it to
the pool on close.javax.mail.NoSuchProviderExceptionpublic void setMaxActive(int maxActive)
public void setMaxIdle(int maxIdle)
public void setMaxWait(long maxWait)
public void setTimeBetweenEvictionRuns(long time)
public void setMinEvictableIdleTime(long time)
public void setUsername(String userName)
setUsername in class org.springframework.mail.javamail.JavaMailSenderImplpublic void setPassword(String password)
setPassword in class org.springframework.mail.javamail.JavaMailSenderImplCopyright © 2005–2018 Alfresco Software. All rights reserved.