Determining a workflow context table cleaner issue
- Workflow not found
- Workflow restarted
How the workflow engine executes against a current during a glide transaction
The workflow engine is a script engine that executes in a specific order. When the workflow engine executes against a current during a glide transaction, it follows these steps:
- Checks for the existence of a workflow on that table.
- If the engine finds a workflow, it checks for the existence of a wf_context.
- If a wf_context is found and it is active, the engine executes the context.
- If the engine does not find a wf_context, the engine creates and executes a wf_context.
If the table cleaner has removed a wf_context that is older than 180 days, and then a user examines an old current and clicks Update, a new workflow starts executing on that current.For more information, see Execution Order of Scripts and Engines in the ServiceNow product documentation.
Workflows re-attached to old records
Some users have reported that workflows re-attach or re-start on old records. If a workflow context is deleted and the original current that was attached to that context is updated, then a new workflow attaches to that current. There are several ways a workflow context can be deleted. For example, a system administrator can delete a workflow context at any time.
In Calgary and earlier releases, there is an entry in the table cleaner that removes wf_context records older than 180 days. To remove this entry in record cleaner, follow these steps:
- In the navigation menu search box, type sys_auto_flush.list.
- Find the entry on the table, wf_context.
- Clear the Active option on the record.