Skip to content
m-szalik edited this page Mar 13, 2016 · 40 revisions

JavaMail extensions project

It helps you to develop applications without any external SMTP servers, and you can still get your emails.

JavaMail extensions project contains two sub-projects

Version

Current version is 1.5.5

	<dependency>
	   	<groupId>org.jsoftware</groupId>
		<artifactId>javamail-file-transport</artifactId>
		<version>1.5.5</version>
	</dependency>

Project for developers

Features

  • No need to configure SMTP server
  • No need to send emails for existing email accounts
  • No risk of sending emails from developer's machines
  • Emails are stored on your disk instead of sent via smtp

How does it work

You can choose Transport from:
name transport class transport description
filetxt org.jsoftware.javamail.FileTxtTransport Emails saved to files in text format (only headers, and text parts)
filemsg org.jsoftware.javamail.FileMsgTransport Emails saved to files in mbox format
nop org.jsoftware.javamail.NopTransport No file is created, only message in logs.

Set default transport in definition of your javax.mail.Session (property mail.transport.protocol).

More / configuration


Project for administrators / production servers

Features

  • Speed up your application and reduce delays while sending emails from your application (application is not waiting for SMTP server)
  • Email delivery warranty if your mailQueue is configured to be persistent

How does it work

Download

http://oss.sonatype.org/content/groups/public/org/jsoftware/javamail

You need to download:

  • javamail-jms-transport = extension which saves messages in JMS queue.
  • javamail-jms2javamail = ejb module which receives messages from JMS queue and sends them via SMTP.

More


Problems and questions

In case of problems or questions contact me by creating an issue on GitHub.