Structure of a Workflow
There are some basic rules that workflows have to follow.
"Workflows" are folders inside the workflow root folder.
The main configuration file for each workflow is
_wfconfig.ps1
. This name cannot be changed.Some data is stored in the sub folder
_wfdata
. Ths name cannot be changed. It is not important to keep this folder. Everything in it can get lost. It contains "last run" timestamps and a serialized version of_wfconfig.ps1
.The workflow folder contains a workflow script. It's name can be configured in the
_wfconfig.ps1
.In case of "state machine workflows" there can be one or more workflow state scripts. All of them start with "S_", but the name can be configured in
_wfconfig.ps1
.For SharePoint workflows you can have a "pre query" script in the workflow folder. It's usage and name is configured in
_wfconfig.ps1
.For all workflows except "PowerShell" workflows you can have a separate "error handling" script that is executed in case of unhandled errors. It's usage an name is configured in
_wfconfig.ps1
.When using the kenaflow embedded workflow templates you will have these files additionally. They can be removed.
.gitignore
_initialize.bat
: This is a shortcut to the next file..._initialize.ps1
: This can be used to create workflow lists, the workflow state field (in case of "state machine" workflows) and the kenaflow defined permission sets.
- You can have other files in the workflow folder - as you want.