You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Imixs-MailPlugin provides a convenient way to send e-mail messages through a corresponding BPMN event.
3
4
The Imixs-MailPlugin is based on the Java Mail API and can be activated by adding the plugin class to the corresponding model definition.
4
5
5
6
_Plugin Class Name:_
6
7
7
8
org.imixs.workflow.engine.plugins.MailPlugin
8
9
9
-
Sending an E-Mail can be configured by the corresponding BPMN event using the [Imixs-BPMN modeling tool](../../modelling/activities.html) in various ways.
Sending an E-Mail can be configured by the corresponding BPMN event using the [Imixs-BPMN modeling tool](../../modelling/activities.html) in various ways.
12
11
13
-
The subject and the body of the e-mail can contain any information from the corresponding workitem. The content can either be plain text or HTML mail. The recipients of the e-mail can be computed on naming attributes of the workitem or by fixed mail addresses or distribution lists.
The subject and the body of the e-mail can contain any information from the corresponding workitem. The content can either be plain text or HTML mail. The recipients of the e-mail can be computed on naming attributes of the workitem or by fixed mail addresses or distribution lists.
15
15
16
16
## The Mail Content
17
17
18
-
The content of the email can either be plain text or HTML. Using the item-Tag a subject or the e-mail body can be combined with any information from the current workitem as also with properties from the imixs.properties file.
18
+
The content of the email can either be plain text or HTML. Using the item-Tag a subject or the e-mail body can be combined with any information from the current workitem as also with properties from the imixs.properties file.
Further configuration is supported by the Imixs-MailPlugin.
97
93
94
+
### Default Sender Address
98
95
96
+
The default sender address will be set with the current user name. The sender address can be changed by the imixs property 'mail.defaultSender'. If the property is defined, the plugin overwrites the 'From' attribute of every mail with the DefaultSender address. If no value is set the mail will be send from the current users mail address.
99
97
100
-
### Default Sender Address
101
-
The default sender address will be set with the current user name. The sender address can be changed by the imixs property 'mail.defaultSender'. If the property is defined, the plugin overwrites the 'From' attribute of every mail with the DefaultSender address. If no value is set the mail will be send from the current users mail address.
102
-
103
98
Example (imixs.properties):
104
99
105
-
# Marty Mail Plugin
106
-
mail.defaultSender=info@imixs.com
100
+
# Mail Plugin
101
+
mail.defaultSender=info@foo.com
107
102
108
-
A subclass of the MailPlugin can change the behavior by overwriting the method 'getFrom()'
109
-
103
+
A subclass of the MailPlugin can change the behavior by overwriting the method `getFrom()`
110
104
111
-
### Testing Mode
112
-
During development you can switch the Imixs-MailPlugin into a Testing-Mode by defining the imixs property:
105
+
### ReplyTo Address
113
106
114
-
mail.testRecipients
115
-
116
-
The property value can contain one ore many (comma separated) Email addresses. If the property is defined, than an e-mail message will be send only to those recipients. The Subject will be prefixed with the text 'TEST: '.
107
+
You can set a explizit replyTo address by setting the imixs.property `mail.replyTo`.
117
108
118
-
Example (imixs.properties):
109
+
# Mail Plugin
110
+
mail.replyTo=marketing@foo.com
111
+
112
+
A subclass of the MailPlugin can change the behavior by overwriting the method `getReplyTo()`
113
+
114
+
### Authenticated Sender
115
+
116
+
You can overwrite the `authenticatedSender` which may be necessary in case of DMARC (Domain-based Message Authentication, Reporting, and Conformance).
117
+
118
+
DMARC checks to see if the email's sender address is actually authorized to send emails for that domain. A conflict can occur if:
119
+
120
+
1. From address: info@foo.com (customer domain)
121
+
2. Actual sender: webmaster@my-company.com (your domain)
122
+
123
+
For DMARC authentication to be successful, at least two conditions must be met:
119
124
120
-
#Testmode
121
-
mail.testRecipients=test@development.com
125
+
1. SPF (Sender Policy Framework): The server from which the email is sent must be authorized in the SPF records of the sender domain.
126
+
2. DKIM (DomainKeys Identified Mail): The email must be signed with a private key of the sender domain.
122
127
128
+
You can set the authenticated sender in Imixs-Workflow by setting the property `mail.authenticatedSender` to the same address as the configured mail host.
123
129
130
+
# Mail Plugin
131
+
mail.authenticatedSender=marketing@foo.com
124
132
133
+
### Testing Mode
134
+
135
+
During development you can switch the Imixs-MailPlugin into a Testing-Mode by defining the imixs property:
136
+
137
+
mail.testRecipients
138
+
139
+
The property value can contain one ore many (comma separated) Email addresses. If the property is defined, than an e-mail message will be send only to those recipients. The Subject will be prefixed with the text 'TEST: '.
140
+
141
+
Example (imixs.properties):
142
+
143
+
#Testmode
144
+
mail.testRecipients=test@development.com
125
145
126
146
### CharSet
147
+
127
148
The default character-set used for the mail subject and body parts is set to 'ISO-8859-1'.
128
-
It is possible to switch to a specific character set . There for the imixs.property key 'mail.charSet' can be used.
149
+
It is possible to switch to a specific character set . There for the imixs.property key 'mail.charSet' can be used.
129
150
130
151
Example (imixs.properties):
131
152
132
-
#Charset
133
-
mail.charSet=UTF-8
134
-
153
+
#Charset
154
+
mail.charSet=UTF-8
135
155
136
156
### Cancel e-mail
137
157
138
-
Sending a e-mail message can be canceled by the application or another plugin by setting the attribute 'keyMailInactive' to 'true'. The attribute is part of the corresponding BPMN event.
158
+
Sending a e-mail message can be canceled by the application or another plugin by setting the attribute 'keyMailInactive' to 'true'. The attribute is part of the corresponding BPMN event.
139
159
140
160
keyMailInactive=true
141
161
@@ -144,22 +164,19 @@ The attribute can be set by the [Imixs-RulePlugin](./ruleplugin.html).
144
164
### Receipients and Event Properties
145
165
146
166
A E-Mail message consists of a list of recipients. The recipients can be mapped to name-fields defined in the BPMN definition.
| rtfMailBody | String | Mail Body (can be plain text or HTML) |
174
+
| namMailReplyToUser | String | Reply To address. If not set the reply address is the sender address |
175
+
| namMailFrom | String | Sender (default is the current user) |
176
+
| namMailReceiver | String (list) | Receiver list (TO) |
177
+
| namMailReceiverCC | String (list) | Receiver list (CC) |
178
+
| namMailReceiverBCC | String (list) | Receiver list (BCC) |
179
+
| keyMailInactive | Boolean | If true, the e-mail will be canceled (can be set by other plugins) |
163
180
164
181
## Deployment
165
182
@@ -171,17 +188,15 @@ The mail resource object is used to send outgoing mails to mail server. See Java
171
188
172
189
### Deployment Descriptors
173
190
174
-
Depending on the server environment the Mail resource need also be defined in the deployment descriptor. See the following example for JBoss/Wildfly Server:
Depending on the server environment the Mail resource need also be defined in the deployment descriptor. See the following example for JBoss/Wildfly Server:
0 commit comments