Oracle® Fusion Middleware Modeling and Implementation Guide for Oracle Business Process Management 11g Release 1 (11.1.1.6.0) Part Number E15176-07 |
|
|
PDF · Mobi · ePub |
This chapter describes how to design human tasks using the different editors available in Oracle BPM. It also describes how associate Human Task with the user tasks in your BPM project.
This chapter includes the following sections:
Section 27.1, "Introduction to Designing Human Tasks in Oracle BPM"
Section 27.4, "Creating a Human Task from the SOA Composite Editor"
Section 27.5, "Implementing a User Task with an Existing Human Task"
Section 27.6, "Editing a Human Task Using the Human Task Editor"
Section 27.7, "Configuring a Human Task Using the Human Task Editor"
For information on how Oracle BPM shows human tasks in the Business Catalog, see Section 14, "Working with Human Tasks".
For more information on how to define Human Tasks using Oracle SOA Suite, see the following chapters in Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite:
Human tasks enable you to model the interaction with the end user in a a BPM process. You must use human tasks to implement the user tasks in your process.
Oracle BPM Suite provides different editors that you can use according to the requirements of the Human Task you are modeling.
Some human tasks features are only available when using them from Oracle BPM Suite. For more information about this, see Section 27.7, "Configuring a Human Task Using the Human Task Editor".
There are different approaches to working with Human Tasks in Oracle BPM:
Creating the Human Task using the Human Task editor
Creating the Human Task using the simplified interface Oracle BPM provides
Use an existing Human Task
The approach you choose depends on how you plan your work, how you divide it between the developers in your team and the complexity of the Human Tasks you are developing.
Creating the Human Task Using the User Task Properties Dialog
Create a BPMN process
Add a user task
From the user task implementation properties dialog, create a Human Task
For more information see Section 27.2, "Creating a Human Task from Oracle BPM Studio".
Create the corresponding taskflows using SOA Suite
Creating the Human Task Using the Human Task Editor:
Create a Human Task from the SOA Composite Editor
For more information see Section 27.4, "Creating a Human Task from the SOA Composite Editor".
Create the corresponding taskflow using SOA Suite
For more information see .
Create a BPMN process with user tasks
Implement the user tasks in the BPMN process using the defined Human Tasks
For more information see Section 27.5, "Implementing a User Task with an Existing Human Task".
Using an existing Human Task:
Create a BPMN process
Add a user task.
In the user task implementation properties dialog, select the existing Human Task.
For more information, see Chapter 27, "How to Implement a User Task With an Existing Human Task".
You can create a simple Human Task using Oracle BPM Studio. The simplified interface Oracle BPM Studio provides hides the complexity of the Human Task editor by exposing the most important fields to configure a Human Task used in a business process. After you create the Human Task using the Create Human Task dialog, you can edit it using the Human Task editor if needed.
Figure 27-1 shows the Create Human Task dialog.
The Create Human Task dialog enables you to define the following properties:
Title
Defines the name of the Human Task that is displayed to end-users in the Oracle Process Workspace and Oracle BPM Worklist applications.
Priority
Specifies a priority for the Human Task. Valid values are between 1 (highest priority) and 5 (lowest priority). The default value is 3.
Outcomes
Specifies the outcome possible outcome arguments of the Human Task. Oracle BPM Worklist displays the possible outcomes you select as the available tasks to perform at run time.
Parameters
Define the Human Task payload. The Human Task data association is based on the parameters of the Human Task. The data association maps the data objects as input arguments.
Outcome Target
Specifies a String data object to store the outcome argument of the Human Task. You can only select one data object. The value of this outcome is one of the values defined in the Outcomes property.
You can create a Human Task from the User Task Properties dialog in Oracle BPM Studio.
To create a Human Task from Oracle BPM Studio:
Edit the BPMN process.
Right-click the user task.
Select Properties.
The Properties - User Task dialog appears.
Figure 27-2 shows the Properties - User Task dialog.
Click the Implementation tab.
Click the Add button next to the Human Task field.
The Create Human Task dialog appears.
Figure 27-1 shows the Create Human Task dialog.
In the name field, enter a name to identify the Human Task.
From they Priority List, select a priority.
Select a Human Task pattern appropriate for your implementation.
For more information about Human Task patterns, see Chapter 30, "Using Approval Management".
In the Title Field, enter a title for the task to display in the client application (Process Workspace and others).
Optionally, you can configure the following:
The outcome
See Section 27.2.2, "How to Configure the Outcome of a Human Task" for information on how to configure the outcome of a Human Task.
The parameters
See Section 27.2.3, "How to Add a Parameter to Human Task" for information on how to configure the outcome of a Human Task.
The outcome target
See Section 27.2.4, "How to Configure the Outcome Target of a Human Task" for information on how to configure the outcome of a Human Task.
Click OK.
The Create Human Task dialog closes and the Human Task field in the User Task Properties dialog shows the Human Task you created.
Click OK.
The User Task Properties closes and saves the implementation you configured for the user task.
When you create a Human Task from Oracle BPM Studio you can configure the outcome of the Human Task. The outcome values you configure appear as the available actions of the Human Task in Oracle BPM Worklist.
To configure the outcome of a Human Task:
In the Create Human Task dialog, click the Browse button next to the Outcomes field.
The Outcomes dialog appears.
Select one or more outcomes, or click the Add button to add a new custom outcome.
Optionally click Outcomes Requiring Comment, to select those outcomes that require comments.
Click OK.
The Outcomes dialog closes and the selected outcomes appear in the Create Human Task dialog, in the Outcomes field.
You can add multiple parameters to a Human Task to build the Human Task payload. Oracle BPM Studio uses this parameters to create the data association of the user task that uses the Human Task.
To add a parameter to a Human Task:
In the Create Human Task dialog, click the Add button in the Parameters table.
The Data Objects dialog appears.
Select a data object from the Data Objects dialog and drop it on the Parameters table.
The selected data object appears in the Parameters table.
Close the Data Objects dialog.
Optionally you can mark the parameter as editable by selecting the Editable column in the Parameters table.
When you create a Human Task you must define an outcome target. The outcome target maps the result of the Human Task to a String data object in your BPM project.You can base the flow of your process on the value of the outcome target using an exclusive gateway.
To configure the outcome target of a Human Task
In the Create Human Task dialog, click the Add button next to the Outcome Target field.
The Data Objects dialog appears.
Select a String data object from the Data Objects dialog and drop it on the Outcome Target field.
To add a new data object, right-click the Data Objects node and select Add.
The selected data object appears in the Outcome Target field.
Close the Data Objects dialog.
The Human Task automatically appears in the HumanTasks predefined module in the business catalog. You can use the Human Task to implement the user task you are editing or other user tasks in the BPM project.
You can edit the created Human Task using the Human Task editor to configure implementation details.
You can edit a Human Task using the User Task Properties dialog or the Human Task editor. Generally you use the Human Task editor for complex human tasks.
Figure 27-2 shows the User Task Properties dialog.
The User Task Properties dialog enables you to define properties using plain text, simple expressions and XPATH expressions:
Title
Defines the name of the Human Task that is displayed to end-users in the Oracle Process Workspace and Oracle BPM Worklist applications.
Priority
Specifies a priority for the Human Task. Valid values are between 1 (highest priority) and 5 (lowest priority). The default value is 3.
Re-Initiate
Restarts the approval process from the beginning
Initiator
Specifies the user who initiates a task. The initiator can view their created tasks from Oracle BPM Worklist and perform specific tasks, such as withdrawing or suspending a task.
Owner
Specifies the User ID of the task owner
Identification Key
Defines a user-defined ID for the task. For example, if the task is meant for approving a purchase order, the purchase order ID can be set as the identification key of the task. Tasks can be searched from Oracle BPM Worklist using the identification key. This attribute has no default value.
Identity Context
This field is required if you are using multiple realms. You cannot have assignees from multiple realms working on the same task.
Application Context
Specifies the name of the application that contains the application roles used in the task. This indicates the context in which the application role operates.
To edit a Human Task using the User Task Properties dialog:
Open the BPMN process that contains the user task implemented with a Human Task.
Right-click the user task.
Select Properties.
The user task properties dialog box appears.
Click the Implementation Tab.
Make changes to the properties in the Human Task Attributes and Advanced sections.
You can add a Human Task to your BPM project from the SOA Composite editor. Typically you do this when you design human tasks before modeling the user tasks in a BPMN process.
You can add a user task to a BPM project using the SOA Composite editor.
To create a Human Task from the SOA Composite Editor:
Select the Application view.
Expand the BPM project where you want to add the Human Task.
Expand the SOA Content node.
Double-click the composite.xml node to open the SOA Composite editor.
From the Component Palette grab a Human Task.
Drop the Human Task in the Components area of the SOA Composite.
The Create Human Task dialog appears.
Enter a name to identify the Human Task.
Optionally, modify the URL for the Human Task namespace.
Optionally, check the Create Composite Service with SOAP Bindings option.
Click OK.
The Human Task component appears in the Component area of the SOA Composite.
The Human Task you created is available to implement the user tasks in your BPM project. For more information on how to do this, see Section 27.5, "Implementing a User Task with an Existing Human Task".
You can create a Human Task using the Human Task editor and then assign that Human Task to the implementation of a user task.
You must also define how the data objects in your BPM process map to the input and output arguments of the Human Task. You can do this using data associations or transformation. For more information on data associations and transformations, see Chapter 8, "Handling Information in Your Process Design".
You can implement a user task using an existing Human Task that you created for another user task or using the Human Task editor.
To implement a user task with an existing Human Task:
Open the BPMN process.
Right-click the user task.
Select Properties.
The Properties - User Task dialog appears.
Click the Implementation tab.
Click the Browse button next to the Human Task field.
The Browse Human Tasks dialog appears.
Select a Human Task from the list.
Click OK.
The Browse Human Tasks dialog closes and the selected Human Task appears in the Human Task field.
Click OK.
The user task uses the existing Human Task for its implementation.
The SOA Composite displays the relationship between the BPMN process and the Human task by adding a wire between them.
When the BPMN Service Engine runs the user task implementation it invokes the Human Workflow Service with the parameters defined in the data association of the user task. When the Human Workflow Service finishes running the Human Tasks it provides the result to the BPMN Service Engine using the defined data association.
To associate the process payload to the Human Task payload you must configure the Human Task, the user task and start events in the BPMN process and create a business object based on the payload xsd file.
To associate the process payload to the Human Task payload:
Create a business object using the Based on External Schema option.
Right-click a module.
Select New and then select Business Object.
Select Based on External Schema.
Click the Browse button.
Select Copy to Project.
Click Browse Resources.
The Type Chooser dialog opens.
Select the type of the business object from the payload xsd file.
Edit the start event in your BPMN process.
Define a custom argument using the business object you created as its type.
Add a process data object to your process using the business object you created as its type.
Define the data associations between the custom argument and data object.
In the Human Task editor, click the Data tab.
Select Add other payload from the list in the Add button.
Select the payload element in the Type Chooser dialog.
In the Process editor, right-click the user task and select Properties.
Define the data associations between the process data object and the task payload.
Configuring complex human tasks usually requires you to use the Human Task Editor to edit them. This allows you to edit properties that are not displayed when you use the simplified interface that Orable BPM provides.
Figure 27-3 shows the Human Task editor.
You can edit a Human Task used in your BPM project using the Human Task editor. Generally you use the Human Task editor to edit complex human tasks.
To edit a Human Task using the Human Task Editor:
Open the BPMN process that contains the user task implemented with a Human Task.
Right-click the user task.
Select Open Human Task.
The Human Task editor appears.
Make changes to the Human Task.
This section covers how to configure those properties that are only available when using human tasks from Oracle BPM Suite.
The rest of the properties are shared with Oracle SOA Suite. For more information on how to configure these properties, see section Creating the Human Task Definition with the Human Task Editor in the chapter Designing Human Tasks from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite.
The Human Task editor enables you to configure the following sets of properties:
General
Enables you to define basic information such as the title, description, priority and owner.
Note that you can localize the title of a Human Task by selecting the Translation option from the list next to the title field and then clicking Build and Internationalized title. For more information on how to define the resource bundle, see section "Specifying Multilingual Settings and Style Sheets" from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite.
For more information on how to configure these properties, see section "Specifying the Title, Description, Outcome, Priority, Category, Owner, and Application Context" from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite.
Data
Enables you to define the message elements that compose the structure of the task payload.
For more information on how to configure these properties, see section "Specifying the Task Payload Data Structure" from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite
Assignment
Enables you to assign a participant to the task and to configure routing policies to drive the task through the defined workflow.
For more information on how to configure these properties, see section "Assigning Task Participants" from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite
Presentation
Enables you to configure the presentation used to display the Human Task, using stylesheets and multilingual settings.
For more information on how to configure these properties, see section "Specifying Multilingual Settings and Style Sheets" from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite
Deadlines
Enables you to specify the duration and expiration of a task.
For more information on how to configure these properties, see section "Escalating, Renewing, or Ending the Task" from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite
Notification
Enables you to configure how to notify the user when the status of the task changes.
For more information on how to configure these properties, see section "Specifying Participant Notification Preferences" from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite.
For information on how to specify an e-mail address for the recipient of the notification, see Section 27.7.1, "How to Specify an E-mail Address for the Recipient of a Notification".
Access
Enables you to configure access policies and restrictions for the content of the Human Task.
For more information on how to configure these properties, see section "Specifying Access Policies and Task Actions on Task Content" from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite
Events
Enables you to specify how to handle BPEL callbacks.d
For more information on how to configure these properties, see section "Specifying Java or Business Event Callbacks" from Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite
Documents
Enables you to configure the Human Task to store task attachments in Oracle UCM Repository. For more information, see Section 27.7.2, "How to Configure Oracle UCM Repository to Store Task Attachments".
Some human tasks features are only available when using humans tasks from an Oracle BPM Suite Installation.
When you use human tasks from an Oracle BPM Suite installation you must take into account the following considerations:
When you create a Human Task using Oracle BPM Suite, the enableAutoClaim property is set to true by default.
The owner property in the process context is set using the participant assigned to the user task that contains the Human Task.
If your process contains an initiator task the creator attribute in the process context is automatically set using the participant assigned to the initiator task.
When you specify the completion criteria for a parallel participant you can set the default outcome as one of the previous outcomes
When using the Human Task editor in a BPM Suite installation, you can specify an e-mail address for the recipient of a Notification.
To specify an e-mail address for the recipient of a notification:
Open the Human Task editor.
Click the Notification tab.
Double-click the Recipient list.
The Recipient list is an editable list, when you double click it, it becomes a text field.
Enter the recipient's e-mail address.
Optionally you can use the buttons next to the Recipient text field to look up the e-mail address in an application server or to specify the e-mail address using XPath.
Note:
When sending a notification to a recipient specified using an e-mail address, the notification service uses the user context of an assignee to obtain the task information to include in the notification.You can configure Human Tasks to store attachments in the UCM repository. These attachments may contain one or more meta-data properties. You can assign values to these properties or configure them to allow the user to provide the value.
To configure Oracle UCM Repository for task attachments:
In the Project Navigator tree, expand the Business Catalog node.
Expand the Human Tasks node.
Double-click the Human Task you want to configure.
The Human Task Editor appears.
Click the Documents tab.
Select Use Document Package.
A section to configure meta-data properties appears. The table already contains the mandatory standard meta-data: Security Group and Document Type.
Optionally add new standard or custom meta-data properties:
Click the Add button.
Click the Name column to select a standard property from the list or to enter a custom name.
Click the Value column to assign a value to the property. Select By Name to provide the text to assign the value to the property, or By Expression to provide an expression.
Click the Display column to select a display mode:
Editable: the user can provide a value in the task form when uploading the attachment.
Hidden: the value does not appear in the task form
Read-Only: the value appears in the task form but the user cannot modify it
Note:
custom metadata is does not apper in the task form, so you must map the value to task payload or provide a static value.