Tuesday, June 2, 2009

empty subject (no subject) in email with grails mail plugin

When sending email using the grails mail plugin, the email subject always ends up empty with (no subject)

this is a known problem. see the link
http://www.nabble.com/Grails-mail-plugin-0.5-:-subject-and-body-always-empty-td20008519.html

The problem happens if you have groovyws-all-0.4.jar in your lib directory. groovyws-all.jar also has javax.mail.* classes packed in there. The fix is as simple unjaring, remove the javax.mail package and rejar it.

hope someone finds this helpful... spent a good half day researching this

1 comment:

Michal said...

In my case helped adding exclusion:


org.apache.geronimo.specs
geronimo-javamail_1.4_spec