[jboss-user] [JBoss jBPM] - Problem while using email template of JBPM
shantanu.u
do-not-reply at jboss.com
Tue Dec 9 14:13:48 EST 2008
Hi
I'm getting a null pointer while using mail templates (mostly due to my config environment ). I'm trying to figure out what's missing.
Here are the relevant things :
1. hibernate.cfg.xml ,jbpm.mail.templates.xml, jbpm.cfg.xml , and my processdefinition.xml are in the same location ( inside the EAR )
2. jbpm.cfg.xml contains
<string name="resource.mail.templates" value="jbpm.mail.templates.xml" />
3. I know email sending works fine because I've been using it without the templates.
4. My template file contains :
| <mail-template name="task-assign">
| <actors>#{taskInstance.actorId}</actors>
| <subject>Task '#{taskInstance.name}'</subject>
| <text><![CDATA[Hi,
| blah blah
| </text>
| </mail-template>
|
| <mail-template name="task-reminder">
| ...
| </mail-template>
|
| <mail-template name="mailToMgr">
| ...
| </mail-template>
|
5. My process definition contains :
<task-node name="taskNodeName" end-tasks="true">
| <event type="node-enter">
| <mail name="mailToMgr" to="someone at somecompany.com" template="jbpm.mail.templates.xml">
| </mail>
| </event>
| ...
| </task-node>
6. When I run this, I get
Caused by: java.lang.NullPointerException
| at org.jbpm.mail.Mail.send(Mail.java:103)
7. On debug of org.jbpm.mail.Mail, I get
Method getMailTemplateProperties(templateName passed is "jbpm.mail.templates.xml")
|
| mailTemplatesResource = "jbpm.mail.templates.xml"
| mailTemplatesElement = [mail-templates: null]
| mailTemplateElements = [[mail-template: null], [mail-template: null], [mail-template: null]]
* What could the problem be ?
* Also, how do I link my tag with a specific <mail-template> ?
* Can I include html as part of email ?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4195411#4195411
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4195411
More information about the jboss-user
mailing list