Handling Non Conformant emails

This page is for technical reference purposes, some knowledge of Java is needed.

Email Processing Failures

JIRA (and so, JEMH) uses the JavaMail library for most of the heavy lifting of email processing.  Sometimes, emails that arrive are not quite compliant to the standard that Javamail supports, and as a result will fail to be processed by JEMH with a variety of possible error messages.  Fixing these messages is difficult but possible, as yet, no such features are yet in JEMH, this means that if mail is delivered that has been generated by a buggy mail-server, there are some changes that can be made to fix the problem, however, doing so means exporting the message (perhaps from JEMH Auditing into a JEMH Test Case), or externally.  If exporting to file, Javamail itself has some tools that can help locate problems:


The current Javamail API used in JIRA 5.2.5 is Javamail 1.4.5.

The Javamail source-code has a variety of utility type classes including 'msgshow' (great naming convention!), these can be built at the command line with just a JDK:

  1. Copy the Javamail jar into the current directory

  2. Copy msgshow.java into the current directory

  3. javac -cp mail-1.4.5.jar msgshow.java

  4. java -cp mail-1.4.5.jar:. msgshow -m < message

The message object can be exported via the JEMH Auditing or TestCase screens.