xAPPnow LOW CODE PLATFORM - User Manual 

Still no account yet?

×

CMMN Training - Chapter 2: Sentries

 
Related subfolder of the training project: "C02"
 
 

Chapter Overview

 
In this training chapter you get familiar with CMMN sentries providing a specific execution control of work.
 
 
Element Description:
 
CMMN sentries are available as entry and exit criterion. An element may have several entry and exit criterions positioned at the border of an element.
 
 
  • Sentry - Entry Criterion
     
  • Sentry - Exit Criterion
 
 
  • An entry criterion can be used for a task, stage or milestone.
  • An exit criterion can be used for a task, stage or case plan.
 
 
Sentries are triggered by events of a source element or by conditions specified for the associated sentry.
 
 
Sentry Event:
 
A sentry event is specified by drawing a flow from a source element to the entry or exit criterion of the destination element.
 
  • complete (frequently used)
  • create
  • disable
  • enable
  • exit
  • fault
  • manualStart
  • parentResume
  • parentSuspend
  • reactivate
  • resume
  • start
  • suspend
  • terminate
     
     
Sentry Condition:
 
A sentry condition can be specified using TypeScript in TAB "Implementation" for the selected sentry.
 
 
 
Tutorial Model: Automation/Case Plan/Training/CMMN/Chapter/C02/Sentry
 
Case Plan Explication:
 
  • The case plan "CasePlan_Sentries" consists of 3 human tasks
  • Start case plan instance activates 2 human tasks "Enter Data 1 [Team A]" and "Enter Data 3 [Team B]"
  • The completion of human task "Enter Data 1 [Team A]" triggers
  • entry criterion "Task 1 complete" of human task "Enter Data 2 [Team B]" which is activated with event "complete"
  • exit criterion "First Name is Appollo" of human task "Enter Data 3 [Team B]" which is activated if the condition is true
  • The completion of human task "Enter Data 2 [Team B]" completes the case plan
 
 
 
CMMN Training - Chapter 2: Sentries
 
 
 

Exercise

 
In this exercise you will get familiar with the basic CMMN elements by implementing the case plan as described above. The case plan will then be published online, where the human tasks of the case plan can be executed directly in the xAPPnow User Portal.
 
 
Exercise 1: Create the Case plan Model
 
Remark: Add your user name as a prefix to the model name to easily filter your personal process in the runtime environment (User Portal, Camunda).
 
  • Step 1: Right click at model tree folder "Automation/Case Plan/Training/CMMN/Exercise/C02" to open context menu "Create Model"
  • Step 2: Enter model name "Username_Sentries"
  • Step 3: Click button "Search" to open dialog "Select Template"
     
 
 
CMMN Training - Chapter 2: Sentries
 
 
 
  • Step 4: Select template "TMPL_Sentry" in dialog "Select Template" with double click or click button "Select"
     
 
 
CMMN Training - Chapter 2: Sentries
 
 
  • Step 5: Click button "OK" in dialog "Create Case Plan Model" to create the new model in selected folder
 
 
 
Exercise 2: Complete the Case Plan Model
 
The case plan template of this exercise already contains 3 human tasks, which are configured with the candidate group. Also the data of the human tasks are mapped. In this exercise you will complete the case plan as described above, by adding sentries to trigger the human tasks activation dependent on human task completion and specific data value.
 
  • Step 1: Drag&drop an entry criterion element from palette on the border of human task "Enter Data 2 [TeamB]" with label "Task 1 complete"
  • Step 2: Select the label of the entry criterion and drag&drop it to the top of the element
     
     
    CMMN Training - Chapter 2: Sentries
     
     
     
  • Step 3: Connect human task "Enter Data 1 [TeamA]" with entry criterion of human task "Enter Data [TeamB]" with default label "[complete]"
     
     
    CMMN Training - Chapter 2: Sentries
     
     
  • Step 4: Drag&drop an exit criterion element from palette on the border of human task "Enter Data 3 [TeamB]" with label "First Name is Appollo"
  • Step 5: Select the label of the exit criterion and drag&drop it to the top of the element
     
     
     
    CMMN Training - Chapter 2: Sentries
     
     
     
Exercise 3: Configure Sentries
 
In this exercise you will configure the sentry condition for the exit criterion, which is activated if the first name is "Appollo"
 
  • Step 1: Select exit criterion to open TAB "Implementation" and then SubTAB "Marker" to define a sentry condition
  • Step 2: Enter "firstName" in textfield "Search data" and press key "Enter" to find attribute "firstName" of business object "caseData1"
  • Step 3: Drag&drop attribute "firstName"  into the left field of "Sentry Conditon"
  • Step 4: Select operator "==" from the combobox
  • Step 5: Enter string "Appollo" in the right field of "Sentry Conditon" to complete it
     
     
     
    CMMN Training - Chapter 2: Sentries
     
     
 
Exercise 4: Publish the Case Plan Model
 
The case plan model has to be published into Camunda process engine.
 
  • Step 1: Click button "Publish" to open dialog "Publish Model"
  • Step 2: Enter username and password
  • Step 3: Click button "OK" in dialog "Publish model" to publish the case plan into Camunda
     
     
     
    CMMN Training - Chapter 2: Sentries
     
 
 
Exercise 5: Publish the User Task Model
 
The case plan related user task model of the human tasks has to be published separately into the xAPPnow User Portal and is directly online.
 
  • Step 1: Double click at one of the human tasks to navigate to the related submodel (all human tasks are using the same user task model)
  • Step 2: Click button "Publish" to open the dialog "Publish Model"
  • Step 3: Enter username and password and keep option "DEFAULT" on the environment
  • Step 4: Publish the user task model
 
 
 
CMMN Training - Chapter 2: Sentries
 
 
 
Exercise 6: Manage the Case Plan in User Portal
 
  • Step 1: Login into User Portal with user "john", who belongs to the group "TeamA".
  • Step 2: Open menu "Case Definition"
  • Step 3: Click button "Start" to start an instance of the selected case plan definition
 
 
 
CMMN Training - Chapter 2: Sentries
 
 
 
  • Step 4: Open menu "My Cases"
  • Step 5: Select the instance of case plan definition "Username_Sentries" you just had started
  • Step 6: Click button "Open" to view active and available tasks of the case plan
     
 
 
CMMN Training - Chapter 2: Sentries
 
 
 
  • Step 7: As expected subdialog "Case Tasks" displays two active human tasks and one available task of the selected case plan. The task "Enter Data 2 [TeamB]" will become active after the "Enter Data 1 [TeamA]" is completed, as modeled in the case plan
 
 
 
CMMN Training - Chapter 2: Sentries
 
 
 
  • Step 8: Open menu "MyTasks" and execute task "Enter Data 1 [Team A]", do not use first name "Appollo"
  • Step 9: Verify subdialog "Case Tasks" displays human tasks "Enter Data 2 [Team B]" and "Enter Data 3 [Team B]"
     
     
 
CMMN Training - Chapter 2: Sentries
 
 
 
  • Step 10: Login into User Portal with user "jane", who belongs to the group "TeamB"
  • Step 11: Execute task "Enter Data 2 [Team B]"
  • Step 12: Verify subdialog "Case Tasks" displays human tasks "Enter Data 3 [Team B]"
     
 
CMMN Training - Chapter 2: Sentries
 
 
 
  • Step 13: Execute task "Enter Data 3 [Team B]"
  • Step 14: Open menu "My Cases" and verify that the instance of currently executed case plan is no longer available
  • Step 15: Open menu "Case Defintion"
  • Step 16: Open case plan definition "Username_Sentries"
  • Step 17: Verify that currently executed case plan instance is in state "Completed"
     
 
CMMN Training - Chapter 2: Sentries
 
 
  • Step 18: Repeat Steps 1 to 5 to execute again the Case Plan
  • Step 19: Open menu "MyTasks" and execute task "Enter Data 1 [Team A]", use first name "Appollo". This will activate the sentry condition defined for the exit criterion in Exercise 3 and the human task "Enter Data 3 [Team B]" will be skipped.
  • Step 20: Verify subdialog "Case Tasks" displays only human task "Enter Data 2 [Team B]"
     
     
    CMMN Training - Chapter 2: Sentries
     
 
 
 
1

Event
"complete"

1. Event
"complete"
The default event of an entry criterion.
2

Entry
Criterion

2. Entry
Criterion
The entry criterion is triggered with event "complete" of human task "
3

Sentry
Condition

3. Sentry
Condition
The condition is specified using TypeScript.
4

Exit
Criterion

4. Exit
Criterion
The exit criterition is triggered by a condition
 
 
1

Enter Model Name

1. Enter Model Name
Enter model name "Username_Sentries"
2

Search Template

2. Search Template
Click button "Search" to open dialog "Select Template"
 
1

Select Template

1. Select Template
Select template "TMPL_Sentry" in dialog "Select Template" with double click or click button "Select"
 
1

Select Entry Criterion

1. Select Entry Criterion
Select entry criterion from Case Plan palette
2

Drag&drop
Entry Criterion

2. Drag&drop 
Entry Criterion
Drag&drop an entry criterion element from palette on the border of human task "Enter Data 2 [TeamB]" with label "Task 1 complete"
3

Move Label

3. Move Label
Select the label of the entry criterion and drag&drop it to the top of the element
1

Connect Elements

1. Connect Elements
Connect human task "Enter Data 1 [TeamA]" with entry criterion of human task "Enter Data [TeamB]" with default label "[complete]"
 
1

Select Exit Criterion

1. Select Exit Criterion
  • Select exit criterion from Case Plan palette
 
2

Drag&drop
Exit Criterion

2. Drag&drop 
Exit Criterion
Drag&drop an exit criterion element from palette on the border of human task "Enter Data 3 [TeamB]" with label "First Name is Appollo"
3

Move Label

3. Move Label
Select the label of the exit criterion and drag&drop it to the top of the element
1

Open TAB Marker

1. Open TAB Marker
Select exit criterion to open TAB "Implementation" and then SubTAB "Marker" to define a sentry condition
2

Search Attribute

2. Search Attribute
Enter "firstName" in textfield "Search data" and press key "Enter" to find attribute "firstName" of business object "caseData1"
3

Drag&drop
Attribute

3. Drag&drop
Attribute
Drag&drop attribute "firstName"  into the left field of "Sentry Conditon"
4

Select Operator

4. Select Operator
Select operator "==" from the combobox
5

Enter Condition

5. Enter Condition
Enter string "Appollo" in the right field of "Sentry Conditon" to complete it
 
1

Click Publish

1. Click Publish
Click button "Publish" to open dialog "Publish Model"
2

Enter Credentials

2. Enter Credentials
Enter username and password
3

Publish Case Plan

3. Publish Case Plan
Click button "OK" in dialog "Publish model" to publish the case plan into Camunda
4

Keep Defaut Environment

4. Keep Defaut Environment
Keep selected the default environment to publish
 
1

Click Publish

1. Click Publish
Click button "Publish" to open the dialog "Publish Model"
2

Enter Credentials

2. Enter Credentials
Enter username and password
3

Keep Default Environment

3. Keep Default Environment
Keep "DEFAULT" environment selected
4

Publish User Task Model

4. Publish User Task Model
Publish the user task model
 
 
1

Open My Cases

1. Open My Cases
Open menu "My Cases" to display an overview of active case plans.
2

Active Case Plan

2. Active Case Plan
Active instance of case plan definition "Sentry". 
3

Open Instance

3. Open Instance
Click button "Open" to view active and available tasks of selected case plan instance.
 
1

Open Case Definition

1. Open Case Definition
Open menu "Case Definition" to display an overview of case plan definitions.
2

Start Instance

2. Start Instance
Click button "Start" to start an instance of a case plan definition.
 
1

Active Tasks

1. Active Tasks
There are two human tasks active to be executed by a user
2

Available Tasks

2. Available Tasks
There is one human task available that according to the Case Plan, will be active after the human task "Enter Data 1 [TeamA]" is completed
1

Active Tasks

1. Active Tasks
Verify subdialog "Case Tasks" displays human tasks "Enter Data 2 [Team B]" and "Enter Data 3 [Team B]"
 
1

Active Task

1. Active Task
Only one human task remains active, the rest have been completed
 
1

Sate Completed

1. Sate Completed
The transition "Completed" automatically triggers when all plan items contained in the case plan model are completed, terminated, or disabled.
With automatic completion enabled (see Chaper 4: Markers), only required plan items have to reach theses states.