File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Other JSE/JEE APIs and the fly likes How to make the JavaMailSenderImpl class to use connection pooling to connect the SMTP server? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "How to make the JavaMailSenderImpl class to use connection pooling to connect the SMTP server?" Watch "How to make the JavaMailSenderImpl class to use connection pooling to connect the SMTP server?" New topic
Author

How to make the JavaMailSenderImpl class to use connection pooling to connect the SMTP server?

Suresh Vadivel
Greenhorn

Joined: Apr 12, 2010
Posts: 2
I am using JavaMailSenderImpl send() method to send my MIMEMessage. Time taken to complete the send method is high and can be optimized as it is creating and closing connections everytime. Moreover need to keep this as synchronous call as there are further flows dependent on this. So planning to use pool of connections and make use of connections from the pool. Please advise how we can achieve this.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39547
    
  27
I don't recall ever hearing about connection pooling for SMTP connections. Is the time it takes to send mails an actual problem, or are you just assuming that it can be optimized and would like to do that?


Ping & DNS - updated with new look and Ping home screen widget
Gaze Lee
Greenhorn

Joined: Sep 03, 2012
Posts: 3
I'm also looking forward a solution to solving this problem, here is another thread that I posted on springsource:

http://forum.springsource.org/showthread.php?133978-Batch-message-consuming-with-Spring-AMQP-amp-Spring-Mail

Can anyone help us please? Any advice greatly appreciated.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to make the JavaMailSenderImpl class to use connection pooling to connect the SMTP server?
 
Similar Threads
Using OracleOCIConnectionPool in WebLogic 6.1
How to Integrate ActiveMa
Connection Pool Implementation ... ?
connection pooling
Thread : Resource allocation