Meaningless Drivel is fun!*
The moose likes Other JSE/JEE APIs and the fly likes Throw exception if mail server doesn�t respond Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "Throw exception if mail server doesn�t respond" Watch "Throw exception if mail server doesn�t respond" New topic
Author

Throw exception if mail server doesn�t respond

Jeppe Sommer
Ranch Hand

Joined: Jan 07, 2004
Posts: 270
Hello,

I am using javaMail API to send e-mails from a web application.

How can I throw an exception if the e-mail server does not respond within i.e. 2-3 seconds after calling the method Transport.send(msg);

I sometimes experiences that there is no connection or I get a slow response time from the e-mail server and the browser is just loading until the message is sent or it throws an SendFailedException, but it takes to long time?!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Throw exception if mail server doesn�t respond
 
Similar Threads
How to send an email using spring framework
SMTP java program...
Not able to send a mail using JAVA code
Anyone else NOT get a confirmation email for SCEA Beta Part II?
JMS Implementation with SwiftMQ