Warning

Sequentiality is never guaranteed in execution when tasks, processes, conditional nodes or message events are not on a process line.


Nodes and execution queue

This appendix describes in what sequence tasks, processes, conditional nodes and message events are executed by the process engine. The sequence is never guaranteed. There are however some rules that are used to determine if and when tasks, processes, conditional nodes and message events are executed. This appendix describes the ordering that applies on such node, as shown in table below. When a process is evaluated a queue is created. The queue is updated every time the process is evaluated. The queue contains all the nodes that have to be executed. If multiple nodes are put on the queue at once this is not done in a specific order. This is important to notice.


TypeNodeRequiredOverall conditionalConditionalCreation in databasePut on queueMoved from queueExecution
ProcessProcessYesYes, when a process is in another process (parent node)NoPrecondition is TRUE (a process line is also a precondition)Line reaches processOverall condition is false, parent node is completedProcess is first on queue
ProcessAdhoc processConditionalYes, when a process is in another process (parent node)YesWhen precondition and overall condition are trueCondition is trueOverall condition is false, parent node is completedProcess is first on queue
TaskTaskDepends on if and what kind of join node is usedYes (parent node)NoPrecondition is TRUEN/AN/AWhen executed with AQ_ExecuteTask
TaskAutomated taskYesYes (parent node)NoWhen precondition and overall condition are trueAfter creationOverall condition is false, parent node is completedtask is first on queue
TaskAdhoc taskConditionalYes (parent node)YesWhen precondition and overall condition are trueN/AN/AWhen executed with AQ_ExecuteTask
ConditionConditionalYesYes (parent node)NoPrecondition is TRUEPrecondition is TRUE (ie. arrow reaches the node) or process profile changesOverall condition is falseconditional is first on queue
ConditionAdhoc conditionalNoYes (parent node)NoWhen overall condition is trueAfter creation or when process profile changesOverall condition is false, parent node is completedconditional is first on queue
EventMessage eventYesYes (parent node)NoPrecondition is TRUE

Incoming message event
EventAdhoc message eventNoYes (parent node)NoWhen overall condition is true

Incoming message event
TimerTimerYesYes (parent node)NoPrecondition is TRUE

Incoming timer event
TimerAdhoc timerNoYes (parent node)NoWhen overall condition is true

Incoming timer event

Examples

Some facts about process Process:

  • Task TaskA fills Person.Name
  • Conditional Process_Condional_1 has condition "Person.Name !=?"

The tables show two possible execution plans. The first plan shows how the process is evaluated now. The second plan shows how it could be executed in future, as the sequence can not be guaranteed


First execution plan:

StepQueue before stepExecutionQueue after step
1

Process is evaluated:

TaskA is put on queue

TaskA


2TaskATaskA is executed
3

Process is evaluated:

TaskB is put on queue

Process_Conditional_1 is put on queue

Process_Conditional_1

TaskB


4

Process_Conditional_1

TaskB

Process is evaluated:

Process_Conditional_1 is removed from queue

TaskC is put on queue

TaskB

TaskC

5

TaskB

TaskC

TaskB is executedTaskC
6TaskC

Process is evaluated:

End node is reached

TaskC
7TaskCTaskC is executed
8

Process is evaluated:

End node is reached 

End node is executed



Second execution plan:

StepQueue before stepExecutionQueue after step
1

Process is evaluated:

TaskA is put on queue

TaskA


2TaskATaskA is executed
3

Process is evaluated:

TaskB is put on queue

Process_Conditional_1 is put on queue

TaskB

Process_Conditional_1

4

TaskB

Process_Conditional_1

TaskB is executed

Process_Conditional_1

5Process_Conditional_1

Process is evaluated:

End node is reached


End node is executed

Process_Conditional_1 is removed from queue



 



When you're using TSL in the displayname of a task, the TSL is rendered when adding the task to the evaluation queue. When the data used in your TSL expression changes after adding the task to the evaluation queue by executing another task, the displayname is not updated.