User Tasks

User Task
A User Task is a typical “workflow” Task where a human performer performs the Task with the assistance of a software application and is scheduled through a task list manager of some sort.
— BPMN 2.0.2 Standard, 10.3.3, User Task

In Flowable, User Tasks are the primary way to interact with humans within a process. Once the execution reaches such a task, a user is required to fill in a form of some sort.

Through forms, it is possible to create and update variables which can be used in other tasks or can be used to control the flow of a process.

Each task can be assigned to one or more people as well as shared with any number of groups. In addition, a task can optionally have a due date.

Example

The following example shows how a process where a user is required to fill a form. The information gathered is used to create an invoice.

User Task

A simple corresponding form could look like this:

User Task

Attributes

Group Attribute Description

General

ID

The unique identifier of the element within the process model.

Name

The name of the element. This is the name displayed in the diagram.

Security policy

The security policy associated with this element.

Documentation

A description and additional information about this element.

Assignment

Owner

The Owner attribute describes who owns the task. The owner can delegate a task to another user who then becomes the assignee. The assignee can then resolve the task which reassigns it to the owner who then decides whether or not the task is completed.

Assignee

Defines the assignee of a task. The assignee is the person who is responsible for the completion of a task. By default, the assignee is set to $INITIATOR which is a special variable that is set to the user who started the process. It is possible to set the assignee directly or through an expression. In both cases, the expected value is the User ID of the assignee.

Candidate users

Defines a list of users that can become assignee by claiming the task. It is possible to set the candidate users directly or through an expression. In both cases, a list of user IDs is expected.

Candidate groups

Defines one or more groups that can become assignee by claiming the task. You can either directly select a group or use an expression. It is possible to set the candidate groups directly or through an expression. In both cases, a list of group IDs is expected.

Participant users

The selected users to add as participant identity links to the task.

Participant groups

The selected groups to add as participant identity links to the task.

Watcher users

The selected users to add as watcher identity links to the task.

Watcher groups

The selected groups to add as watcher identity links to the task.

Details

Form reference

The form associated with the User Task. Once a user opens the task, he or she is presented with the referenced form. It is possible to create a new form, reference an existing one or delete the current reference.

Validate form fields (server-side)

If the form is submitted and validate form fields expression evaluates to true, form fields are validated on the back send according to the form model restrictions.

Form properties

Deprecated: Sets the form properties. Only relevant if you work with a legacy version of Flowable Tasks.

Task listener

Sets Task Listeners for this task. This lets you react to the following events:

  • Create: Occurs when the task has been created and all task properties are set.

  • Assignment: Occurs when the task is assigned to somebody. Please note that the Assignment event is fired before the Create event.

  • Complete: Occurs when the task is completed and just before the task is deleted from the runtime data.

  • Delete: Occurs just before the task is going to be deleted or completed.

Expose as action to object

Allows you to expose the activation action to objects other than the process, such as a user or conversation.

Asynchronous

Sets the User Task as "asynchronous" which introduces a wait state once the execution reaches the task.

In most cases, there should not be a reason to use this attribute in a User Task.

Expose as an action message

Allows you to expose the activation action as a message to a conversation.

Folder path for uploaded content items

The folder path where uploaded content items for this task are uploaded.

Execution listeners

Active Execution Listeners of the activity. This lets you react to the following events:

  • Start: Occurs when the activity is started.

  • End: Occurs when the activity is completed.

Priority

An integer number denoting the priority of the task.

Due date

The due date of the task. No due date is the default and there are three different options to set a due date:

  • Relative: Add or subtract a number of days, months or years relative to the current date.

  • Absolute: Set an absolute date.

  • Expressions: Use an expression to dynamically calculate a date.

Skip expression

Defines an expression which is evaluated before executing the task. If it evaluates to true, the task is skipped.

Skip expressions are only be evaluated if there is a process variable _ACTIVITI_SKIP_EXPRESSION_ENABLED with the boolean value true.

Is for compensation

Determines whether the activity can serve as a compensation for another activity.

Multi instance

Multi instance type

Determines if multiple instances of this activity are created. There are three choices:

  • None (default, only one instance is created).

  • MI parallel (activities are created in parallel. This is a good practice for User Tasks).

  • MI sequential (activities are created sequentially. This is a good practice for Service Tasks).

Once a type other than None is chosen, the following options appear:

  • Collection: The number of instances is determined by the elements of a collection. For each element in the collection, a new instance is created.

  • Element variable: The variable under which each element is available to the newly created instance.

  • Element index variable: The variable under which the current number of iterations is stored.

  • Completion condition: An expression which, if it evaluated to true, stops the creation of new instances.

  • Cardinality: An expression or numeric value (integer) which determines how many instances are created.

Visual

Font weight

The font weight of the element in the diagram.

Font size

The font size of the element in the diagram.

Font color

The font color of the element in the diagram.

Font style

The font style of the element in the diagram.

Background color

The background color of the element in the diagram.

Border color

The border color of the element in the diagram.