users@glassfish.java.net

Setup of Glassfish Email to use remote server and Port

From: <glassfish_at_javadesktop.org>
Date: Fri, 21 Mar 2008 13:58:36 PST

Greetings:

   I am attempting to use the Javamail Session resource in Glassfish to send email using an SMTP server that is *not* local to the machine running Glassfish.

   I have gone through the (incredibly vague) instructions for setting up a Javamail Session on Glassfish, but all those instructions do is suggest that I set properties using properties known in Javamail. This is somewhat OK, I guess, but the Javamail properties I know about seem to be ignored by the server!

My attempts to put authentication information (using smtp.mail.username and smtp.mail.password) are failing. The server I am attempting to use communicates on a port other than 25; my attempts to get Glassfish to stop attempting to use that port have also failed.

Worse: Glassfish keeps insisting on looking on localhost for the SMTP server, even though I keep trying to get it to go to a remote one.

Glassfish, frankly, does not appear to be capable of handling email unless the server is on the machine, using the standard port, and does not implement authentication. This is a major inadequacy (the security issues alone will make Glassfish's handling of email inadequate!) that could well force me to move to JBoss 5 or some other application server!

Could someone either give an example of how to set up Glassfish so that a client can use a remote SMTP server with authentication, or confirm to me that this application server is indeed incapable of offering email sessions with any flexibility so that I won't waste my time on it any more???

Thanks in advance for any help on this matter.
[Message sent by forum member 'factor3' (factor3)]

http://forums.java.net/jive/thread.jspa?messageID=265237