Email activity delivery algorithm

Email activity delivery requires the JavaMail API. Email messages are easily created and delivered through the SMTP server interface of this API and the object-oriented model of the standard MIME email message format. Delivery is started on the day the business user specified in the email activity. The HCL Commerce scheduler launches a job at the specified date and time, which starts the email activity delivery.

The email activity delivery algorithm uses the following process:
  1. Look up the email promotion scheduled for delivery, including the target customer segment and email template.
  2. Query the target customer segment for the email activity to obtain the list of recipients.
  3. Verify that each recipient opts in to receive email, as specified in the EMLUSRRECV table.
  4. Read the email configuration data through the administrative console.
  5. Connect to the SMTP server according to the outbound email configuration.
  6. Iterate through every recipient by calling the email template for each recipient.
  7. Add the inbound account address as the "sender" email address, and the outbound account address as the "replyTo" address.
  8. Send the email message.
  9. Disconnect and update the state of the email activity.
Ensure that your SMTP server adheres to the following Requests For Comments (RFC) specifications:
  1. Email addresses adhere to RFC 822 (* enforce this specification for registration).
  2. POP3 server as defined in RFC 1939 capable of delivering Delivery Status Notification(DSNs) as defined in RFC 1894.
  3. SMTP server as defined in RFC 2821.
For more information about RFC specifications, see http://www.ietf.org/rfc.html