Basic Process Building Best Practices

Name and Connect Steps Correctly

When creating a process, you must have a fully connected diagram with correctly named steps before you are able to save:

If you try to save the above incomplete diagram, you will receive errors. Red errors as shown below indicate a problem that prevents the diagram from being saved

The errors indicates two problems - the steps have not been named, and there are missing connectors. Even in early stages of building a process you should make the process complete, if only for the purpose of saving the diagram:

This diagram is now valid and can be saved without errors. To continue building out the process, add more steps and connectors. You can delete the connector from Step 2 to End and add a number of steps, then connect the last step to End

Add some steps and reconnect the last step with the End shape:

You can save this diagram but you will get the orange Validation warning indicating that Step 2 has more than one default connector. If you get a Validation warning, the diagram is properly saved however you must resolve the issue in the warning or you will have unexpected results when running the process. Once the diagram is saved, you can go and either make one of the connectors parallel, or add a condition so that only one connector is chosen:

Click the Start Parallel Branch checkbox to run this step in parallel with Step 3, or add a condition to choose whether Step 3 or Step 3a is run.

If you select the Parallel option, the diagram will update as shown below. The connector between Step 2 and Step 3a is blue, indicating a parallel connector, and the yellow dashed connector (contingent connector) indicates that both branches must complete before Step 4 is run.

If you add a couple more steps and again have multiple default connectors, you will need to save before you can add conditions:

When you save you will get the same orange Validation warning, but the diagram will be saved, and then you can add a condition:

Save often
  • Save often as you are building your diagrams. If the Salesforce session times out, you may lose your work.
  • Work done in the process designer canvas area (adding steps, connectors, etc) will not auto-save, and will not prevent your session from timing out if you do not save periodically.
Handle cycles
  • If possible get rid of cycles between automatic steps.

There are possible situations where you may need to make a cycle that will include automatic steps and/or escalation to system (that will make step automatic). In this case some loops (with many iterations or even recursive) can make a lot of step proceedings or re-assignments, etc., and this is not good for your application: steps history is saved and it's total size will increase with each loop iteration. This may cause quick reach of Salesforce limits or data storage capacity restrictions.

The way to solve this problem can be:

  • Make some steps in loop manual
  • Add an action that will clear step history and trigger it inside loop
  • Add a condition that will force loop to be finished after some quantity of iterations