Useful Task Attributes

Table of Contents

Cyclic Tasks

Tasks with cycle attributes are re-activated after completion. The number of re-activations can be either predetermined by a fixed number or dynamically determined by a condition that has to be met for a task to stop cycling. Tasks can be re-activated immediately once completed, or after a certain time interval has passed.

Cycle until An expression defining the conditions under which a task will stop cycling.

Note: To create a task that cycles indefinitely, type forever() in the cycle until field.

Example
The Reduce fever plan should continue to cycle until the expression Temperature = < 100 becomes true.
Number of cycles An integer defining the number of times a task will be repeated.

Example
The Take blood sample action needs to be executed twice in a Glucose Tolerance test.
Cycle Interval An integer defining the time interval between cycles (the time unit is hours).

Example
There should be a 2-hour interval between each execution of the Take blood sample action in a Glucose Tolerance test.

Automatic Tasks

The automatic property is only applicable to actions and decisions. Actions and decisions that are automatic do not require end-user confirmation to complete; they are performed by the engine in the background. By default, tasks are non-automatic.

Optional Tasks

Defining a task as optional makes the task unnecessary for the completion of the process-description.

Typically, tasks are non-optional, that is, mandatory. This means that their parent-plan can only complete if the task is completed or discarded. As long as the task is dormant or in progress, the parent-plan remains in progress. When a task is defined as optional, its parent-plan can complete even if the task is dormant.

Plans: Abort & Terminate

Plans have two task-specific attributes, which can interrupt the flow of the process:

Abort Condition A truth-valued expression indicating the conditions under which the task should abort. Once this condition is met, the plan’s state is set to discarded. All tasks within the plan that have not been completed are discarded as well.
Terminate Condition A truth-valued expression indicating the conditions under which the task should terminate. Once this condition is met, the plan’s state is set to completed. All tasks within the plan that have not been completed are discarded.

If the abort condition is used in a plan set in a workflow as in the figure above, because the plan is discarded, the tasks following the plan are discarded as well. Alternatively, if the terminate condition is used, the plan completes, and the workflow can continue.

Note: Abort conditions are only checked when scheduling constraints have been met, whereas termination conditions are checked in advance.

Tallis Training (http://acl.icnet.uk/TallisTraining/)

© Cancer Research UK