Things to ponder with Alfresco (Part-II: Workflow Design)

If you are planning to do so, here are few lessons I have learned –
- Simplicity – We got a lot of benefits just by keeping our process definition simple and neat. Don’t add unnecessary steps which will cause confusing steps for the end users.
- Right things at right place – Alfresco is very flexible in terms of business logic implementation. You will always have multiple options to carry out same operation. Web Scripts, Java classes or Web Service and you are tempted to use different things at times. Decide one approach and stick to it. Put as much as logic in the workflow and don’t spread across the workflow business logic outside the workflow.
- Loops are evil – Loops in the workflow actions are daunting at times. Rethink on the circular steps in the workflow and make sure you are not violating the “simplicity” rule.
- Blocking is good sometimes – Next bigger decision is synchronous or asynchronous operations. All the operations which might result in inconsistent states can be synchronous i.e. transactional. Asynchronous operations are better in terms of responsiveness. Sending e-mails could be asynchronous tasks as you people can receive emails after couple of seconds, but if it is related to pushing records to a queue, let it be synchronous. You got the idea!