‘Wait Condition’ in Workflow Explained
I was asked by one of my blog followers to explain ‘Wait Condition’ in Workflow.
To explain this better, I took a small scenario
- Send an Email to Opportunity Owner, whenever an Account has been assigned to the Opportunity
Configuring Work Flow :
- Create a workflow on Opportunity which triggers when ‘Record is created’
- Add a “Wait Condition” to check, if Account got assigned to Opportunity (I.e., Opportunity. Account ‘Contains Data’)
- Create an Email Activity, if ‘Wait Condition’ met
- Save and Activate Workflow
Test the Workflow
- Create new Opportunity
- Check the Waiting job in ‘System Jobs’
- Since we have the Wait condition set in our workflow, the Job will wait until the condition met
- Associate ‘Account’ to the ‘Opportunity’
- Check the Waiting Job now and it should have completed.
- New Email created in system as the follow up action
Key Points to consider before using Wait Conditions:
While the ‘Wait conditions’ are useful in case of the timer related tasks which will be achieved with no coding, excessive use of wait conditions has a downside.
- Performance:
- Each waiting workflow instance carries performance overhead. The more waiting workflow you have, the more server resources will be consumed by the Asynchronous Processing Service.
- If you change the logic in your workflow and republish (like update the text of the email sent to your client), it does not change waiting workflow instances. For example, if you change the renewal email frequency to 15 days rather than 30 days, any workflow instances that are waiting will not be updated.
🙂
Comments (0)
Trackbacks (1)
Leave a comment
Trackback
-
February 19, 2017 at 10:21 PMWait Condition with Parallel Wait Branch | Rajeev Pentyala - Dynamics CRM Blog