Apache Commons logo Commons Email
These are the release notes for Commons Email version 1.1.

Introduction

Commons Email aims to provide a API for sending email. It builds on the JavaMail API with the aim of presenting a simplified API which is easy for developers who are not mail experts to use. It is a compact component with a small number of classes.

The Commons Email website is the source for the most recent information, downloads, reports, and bug status:

http://commons.apache.org/email/

This is a maintenance release which fixes several bugs present in the 1.0 release and adds a number of small enhancements requested by users. All current users are encouraged to upgrade.

Changes from 1.0

Compatibility

  • Java 1.4 or later is now required. Earlier versions are no longer supported by Sun.
  • JavaMail 1.4 or later and JavaBeans Activation Framework 1.1 or later are now required.
  • The protected field org.apache.commons.mail.HtmlEmail.inlineImages is now deprecated. Its function is now performed by the org.apache.commons.mail.HtmlEmail.inlineEmbeds field; the new field is a Map instead of a List. The change was made as a part of EMAIL-50. Clients that have subclassed HtmlEmail should change their implementations accordingly.

Notable bugfixes

  • EMAIL-50: HtmlEmails were not being constructed correctly; several email clients were not displaying attachments or embedded images properly. As part of the same problem, duplicate embeds were not being handled correctly.
  • EMAIL-1: Email.setContent() was not taking a specified charset into account. Additional setContent() overloadings were also added to address common use cases.

Notable enhancements

  • EMAIL-35: HtmlEmail now supports the embedding of any DataSource implementation. Specific methods were added for File and URL objects, removing the need for clumsy circumlocution.
  • Character set handling and encoding has been overhauled to use the JDK 1.4 character set support. All charsets supported by the Java VM are now recognized and handled appropriately in Email.setCharset() and Email.setContent() calls.
  • HtmlEmail performance has been slightly improved.
  • The MIME structure of MultiPartEmail and HtmlEmail has been improved.

Requirements

J2SE environments

Commons Email requires JavaMail 1.4 or later. The proprietary Sun implementation is available at:

http://java.sun.com/products/javamail/

However, the Apache Geronimo project (http://geronimo.apache.org) provides a J2EE-certified implementation of the JavaMail 1.4 specification licensed under the Apache Software License.

Commons Email also requires the JavaBeans Activation Framework. The proprietary Sun implementation is available at:

http://java.sun.com/products/javabeans/glasgow/jaf.html

Apache Geronimo likewise provides an implementation under the Apache Software License.

Commons Email has been tested with JDK 1.4.2_15 and JDK 1.5.0_12.

J2EE environments

Commons Email is compatible with all certified Java Enterprise Edition 5 implementations; no further dependencies are required.

Java 2 Enterprise Edition 1.4 users must ensure that the versions of JavaMail and JAF indicated above are available to their applications; the J2EE 1.4 specification only requires earlier versions.

Earlier versions of J2EE are not supported.