Sending emails from Openbravo workflows

Sometime ago, Openbravo made that big leap by integrating their wonderful ERP with a workflow engine. The Workflow Engine of choice was Activiti. You can download the module from here. Refer to the wiki page for more background.

The integration module available on forge is based on Activiti 5.8.

Its a world of goodness – Openbravo and Activiti together. Once you and your customers start experiencing the results, there is no going back. Workflows will climb their way up from a distantly relevant “Nice to Have” to an enriching “That’s easy, lets have that” position in your scheme of ERP implementation.

While discussing Openbravo workflows for an organization, a customer asked “Can I have an email sent at this point in the flow?”. Activiti makes it easy to send out emails through email tasks. There are a number of articles on the internet, so I am not delving into email tasks now.

They are an organization that have their email hosted on a google domain. For example, if the emails were sent out using gmail, the activiti.cfg.xml would look like this:

<property name=”mailServerPort” value=”587″ />
<property name=”mailServerHost” value=”tls://smtp.gmail.com:587″ />
<property name=”mailServerDefaultFrom” value=”sender@gmail.com” />
<property name=”mailServerUsername” value=”sender” />
<property name=”mailServerPassword” value=”*******” />
<property name=”mailServerUseTLS” value=”true” />

They are an organization that have their email hosted on a google domain.

When the workflow was fired, Activiti produced error messages and it was evident that it didn’t like the TLS part of config. It turns out that Activiti 5.8 doesn’t support useTLS parameter.

TLS is addressed in this patch. We applied the patch on top of Activiti 5.8 thats shipped with the integration module and that did the trick for us, and now emails go out from Openbravo.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: