Download presentation
Presentation is loading. Please wait.
Published byBaldric Collins Modified over 9 years ago
1
37 Copyright © 2007, Oracle. All rights reserved. Module 37: Executing Workflow Processes Siebel 8.0 Essentials
2
2 of 50 Copyright © 2007, Oracle. All rights reserved. Module Objectives After completing this module you should be able to: Describe the workflow execution architecture List several ways to invoke workflow Invoke a workflow process using a run-time event Invoke a workflow process using a custom control Why you need to know: There are multiple ways to invoke a workflow process and you need to understand the choices available
3
3 of 50 Copyright © 2007, Oracle. All rights reserved. Executing Workflow Processes Workflow processes are executed either in The user’s application object manager Supports synchronous processing A separate server component known as the Workflow Process Manager component Supports asynchronous processing In both cases workflow processes are executed using the Workflow Process Manager business service Is often referred to as the Workflow Engine
4
4 of 50 Copyright © 2007, Oracle. All rights reserved. Synchronous Workflow Processing Is typically executed in the user’s application object manager User is forced to wait until the workflow completes (or pauses) Hourglass icon appears Can be triggered by an action on the part of the user: Directly by clicking a button or menu item Indirectly by performing a record or applet operation Is used to execute specific business logic that: Is triggered by the user’s activity Should be completed before the user continues activity
5
5 of 50 Copyright © 2007, Oracle. All rights reserved. Asynchronous Workflow Processing Is executed in the Workflow Process Manager server component User (if any) is not prevented from continuing activity Is typically triggered by a change in the value of some column in a database table Can respond to changes not associated with user activity For example: updates resulting from Enterprise Integration Manager imports Can respond to conditions that exist for some threshold period of time Is used to execute specific business logic when a specified condition is satisfied Will be discussed in the following module
6
6 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking Workflow Processes A workflow process can be invoked by a variety of mechanisms Run-time events Custom buttons and menu items Workflow policies Programmatically (that is as part of script) This module Next module Beyond scope Workflow Policies Runtime Events Custom Control
7
7 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking via Workflow Policies A workflow policy is a defined set of conditions and actions Actions are executed when conditions are met Example: When a service request priority = Critical: Send urgent message to service request owner Update service request priority to Very High Conditions Actions IF = True THEN Workflow Policies Runtime Events Custom Control
8
8 of 50 Copyright © 2007, Oracle. All rights reserved. Requirements for Workflow Policies Enable the Workflow Management component group Select Administration > Server Configuration > Enterprises > Component Groups Workflow Component Definitions
9
9 of 50 Copyright © 2007, Oracle. All rights reserved. Workflow Component Definitions Workflow Component Group consists of six server component definitions
10
10 of 50 Copyright © 2007, Oracle. All rights reserved. Steps for Defining a Workflow Policy 2.Create a Workflow Policy Action 3.Create a Workflow Policy 1.Create a Workflow Group 4.Generate Database Triggers 5.Start Workflow Monitor Agent 0/5
11
11 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking via Runtime Events A runtime event responds to an action or occurrence from a single user within a single user session Workflow Policies Runtime Events Custom Control
12
12 of 50 Copyright © 2007, Oracle. All rights reserved. Run-Time Events Are a mechanism that allows customer-configured processing to be triggered by user activity Consist of: A specification of some user activity such as: Record being updated Navigating to/from an applet The resultant processing Workflow One or more calls to business services Known as an action set
13
13 of 50 Copyright © 2007, Oracle. All rights reserved. Examples of Runtime Events Event Object Type: Buscomp Event: WriteRecord Event Object: Event Object Type: Buscomp Event: PreDeleteRecord Event Object: Event Object Type: Buscomp Event: CopyRecord Event Object:
14
14 of 50 Copyright © 2007, Oracle. All rights reserved. Run-Time Events Continued Can be defined for three types of objects: Application Examples: logging in, logging out Applet Examples: displaying an applet, displaying a record Business component Examples: Querying, deleting a record, setting a field value Are fired when a user performs the corresponding activity
15
15 of 50 Copyright © 2007, Oracle. All rights reserved. Business Component Events Business component events often come in pairs such as: PreDelete/Delete PreSetField/SetField PreWriteRecord/WriteRecord The Pre- event is fired immediately prior to object manager executing the operation Example: PreWriteRecord executes customer processing before the record is saved Allows for possible verification of field values The other event is fired immediately after the object manager executes the action Example: WriteRecord executes customer processing after the record is written Allows for follow-on processing after a record is saved
16
16 of 50 Copyright © 2007, Oracle. All rights reserved. Adding a Run-Time Event to a Workflow Process A run-time event can be added to a workflow process as a condition on the connector out of a: Start step Used to invoke the workflow Wait step Used to resume the workflow User interact step Used to resume the workflow Add run-time event here
17
17 of 50 Copyright © 2007, Oracle. All rights reserved. Example: This workflow process changes the SR priority to High when Area = Network The process is invoked when a service request is created or updated and then saved Example of a Runtime Event in Workflow Runtime event defined here
18
18 of 50 Copyright © 2007, Oracle. All rights reserved. Using Run-Time Events in Workflow Continued Specify the triggering event in the detail applet for the workflow step branch following the Start step Business Component Events are most common for invoking Workflow processes Example: Specify an action that occurs to a field in the BC which will invoke the process Select type of event Specify BusComp to monitor for the event Specify event to monitor
19
19 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking a Workflow Using a Run-Time Event 0/3 1. Add the Run-Time Event 2. Deploy and Activate the Workflow 3. Reload the Run-Time Events
20
20 of 50 Copyright © 2007, Oracle. All rights reserved. 1. Add the Run-Time Event Create the workflow process as usual Select the connector to attach a run-time event Must be a start, wait, or user interact step In the properties window, specify the triggering event Caution: A workflow with a run-time event on the start step cannot be tested with the workflow simulator Select connector Specify the event type, business component, and event to monitor 1/3
21
21 of 50 Copyright © 2007, Oracle. All rights reserved. 2. Deploy and Activate the Workflow In Siebel Tools, deploy the event In the Siebel client, activate the event 2/3
22
22 of 50 Copyright © 2007, Oracle. All rights reserved. 2. Deploy and Activate the Workflow Continued Activating the event automatically registers the run-time event and associated workflow with the Siebel run-time event engine Creates an action set that invokes the Workflow Process Manager 2/3 Row ID of activated workflow Business Service, method to invoke Arguments to pass in
23
23 of 50 Copyright © 2007, Oracle. All rights reserved. 3. Reload the Run-Time Events Navigate to Administration - Runtime Events > Events Select Menu > Reload Runtime Events Updates the run-time event engine with the new run-time event Not necessary to query for the specific run-time event Run-time event created by activating the workflow process 3/3
24
24 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking Workflow Processes via Custom Control Use Control User Properties to customize application behavior User clicks a button on an applet that launches a Workflow process Workflow Policies Runtime Events Custom Control
25
25 of 50 Copyright © 2007, Oracle. All rights reserved. Example of Invoking from Custom Control If Currency is USD, set price list to Americas Price List Specify Workflow process to invoke in the Control User Properties for the control
26
26 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking Workflows Using a Custom Control User explicitly clicks a custom button or menu item to invoke the workflow Configuration involves applet user properties Custom menu item that invokes a workflow
27
27 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking a Workflow Using a Custom Menu Item Create a command object Specify a value for the Method property Add an applet method menu item to reference the command
28
28 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking a Workflow Using a Custom Menu Item Continued Add a new Applet User property that associates the workflow to be invoked with the new named method Invoke this business service and method and … … pass in these pairs of argument names and values
29
29 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking a Workflow Using a Custom Button Create a custom control for the button Specify a value for the Method Invoked property Add a new Applet User property that associates the workflow to be invoked with the new named method Create an applet user property specifying the workflow to execute when the named method is invoked Specify a user- defined name for a Method to invoke on the control
30
30 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking a Workflow Process Explicitly The Workflow Process Manager business service can be referenced explicitly: In a script As parameters in declarative configuration Developers must specify: The name of the business service and method The name of the workflow process and other parameters as input arguments Often the RowId parameter must be passed in
31
31 of 50 Copyright © 2007, Oracle. All rights reserved. Invoking a Workflow Process Explicitly Continued A workflow process can also be executed using the business service simulator Is an alternative way of testing new workflows Business service that executes workflow processes Provide name of workflow process as input argument
32
32 of 50 Copyright © 2007, Oracle. All rights reserved. Generate Triggers RequiredNot Required WF Monitor Agent RequiredNot Required Runtime EventNot UsedInvokes processNot Used SynchronousAsynchronous (runs in background) Synchronous (runs in user session) Runs on Mobile Client No (runs on Siebel Server) Yes Comparing Different Methods Workflow Policies Runtime Events Custom Control Use different methods for different needs
33
33 of 50 Copyright © 2007, Oracle. All rights reserved. Which method is best for each scenario? 1.Send out a welcome letter each time a new account is created 2.Send out welcome letters at the end of the day to all new accounts that were created that day 3.Send an email alert to the manager when SR Status = Critical 4.Send an email alert to the manager when SR Status = Critical for more than 1 hour 5.Click Send Info (a new button) on the Account screen to send an account summary to the Team Lead Workflow Scenarios Workflow Policies Runtime Events Custom Control
34
34 of 50 Copyright © 2007, Oracle. All rights reserved. Administration, Monitoring, and Diagnostics Detailed information allows better tracking and managing of workflow instances Policy and Frequency Analysis View Workflow Instance Monitoring View Workflow Instance Deployment View 0/4 Workflow Instance Admin View
35
35 of 50 Copyright © 2007, Oracle. All rights reserved. Workflow Instance Deployment View Used to set Monitoring Level for Workflow processes Parameter changed at runtime—no need of server restart 1/4 Monitoring Level
36
36 of 50 Copyright © 2007, Oracle. All rights reserved. Understanding Monitoring Level Performance impact Monitoring level introduces performance overhead Recommended production setting is 1-Status * In Debug mode, data is written to disk after every step * In Detail, data is written at the end LevelsRecord Process Instance Record Step Instance Record Process Properties Performance Impact 0-NoneNNone 1-StatusYNone 5% 2-Progress YAll StepsNone25% 3-Detail*YAll StepsAll steps60% 4-Debug*YAll Steps 75% 1/4
37
37 of 50 Copyright © 2007, Oracle. All rights reserved. Policy and Frequency Analysis View Used to display a log of all the policies executed in a single group monitored by Workflow Monitor Agent Provides information about the number of times a Workflow policy executes and execution trends Log: Lists Workflow policies Chart: Displays execution frequency of a selected policy in chart form 2/4 Displays executed policies in top applet, frequency chart in bottom applet
38
38 of 50 Copyright © 2007, Oracle. All rights reserved. Workflow Instance Admin View Lists all instances in Running, Waiting, or Error states Allows manual recovery 3/4 Workflow Instance Admin View Lists all process properties data Lists all persisted instances Lists all related instances
39
39 of 50 Copyright © 2007, Oracle. All rights reserved. Workflow Instance Monitor View Lists all instances whose monitoring levels are set Integrated with chart server to display aggregate information 4/4 Process Instances applet shows detail Workflow Instance Monitor view
40
40 of 50 Copyright © 2007, Oracle. All rights reserved. Module Highlights Workflow processes are executed in the Workflow Process manager in either the application object manager or in a server component Can be executed either synchronously or asynchronously A workflow process can be invoked by a variety of mechanisms Run-time events Custom buttons and menu items Workflow policies Run-time events are a mechanism that allows customer- configured processing to be triggered by user activity
41
41 of 50 Copyright © 2007, Oracle. All rights reserved. Lab In the lab you will: Invoke a workflow from a custom menu item Invoke a workflow using a run-time event
42
42 of 50 Copyright © 2007, Oracle. All rights reserved. Appendix Steps for Defining a Workflow Policy
43
43 of 50 Copyright © 2007, Oracle. All rights reserved. Steps for Defining a Workflow Policy 2.Create a Workflow Policy Action 3.Create a Workflow Policy 1.Create a Workflow Group 4.Generate Database Triggers 5.Start Workflow Monitor Agent 0/5
44
44 of 50 Copyright © 2007, Oracle. All rights reserved. 1. Create a Workflow Group A workflow group is a collection of workflow policies that are monitored concurrently To create a workflow group, select Administration - Business Process > Policy Groups Monitor high frequency policies 1/5
45
45 of 50 Copyright © 2007, Oracle. All rights reserved. 2. Create a Workflow Policy Action Actions initiate a workflow process One policy can initiate several actions One action can be reused by several policies To create an action, select Administration - Business Process > Actions Specify Run Workflow Process program Specify workflow process to invoke 2/5
46
46 of 50 Copyright © 2007, Oracle. All rights reserved. 3. Create a Workflow Policy To create a workflow policy, select Administration - Business Process > Policies 3/5 Associate action to invoke workflow process Workflow process to be invoked by policy Create policy
47
47 of 50 Copyright © 2007, Oracle. All rights reserved. Triggering Policy Actions All conditions must be met and the policy duration must be satisfied to trigger the workflow policy actions Duration set to zero means policy is triggered as soon as the conditions are met
48
48 of 50 Copyright © 2007, Oracle. All rights reserved. 4. Generate Database Triggers Workflow policies use database triggers to identify which records satisfy policy conditions A trigger is a process or a stored procedure attached to a table that fires when a specified data modification event occurs When a trigger fires against a Policy Condition, a record is inserted in the Escalation Request Table (S_ESCL_REQ) S_ESCL_REQ contains all the rows in the database that could trigger a policy to take action 4/5 Generate Database Triggers Record is inserted, updated, or deleted S_ESCL_REQ Table updated
49
49 of 50 Copyright © 2007, Oracle. All rights reserved. 4. Generate Database Triggers Continued To generate triggers, select Administration - Server Management > Jobs Create new Job and select Generate Triggers Specify parameters Click Start to start Component Job 4/5
50
50 of 50 Copyright © 2007, Oracle. All rights reserved. 5. Start Workflow Monitor Agent Monitors all policies within a single Workflow group Create a custom Workflow Monitor Agent component definition to specify a Workflow group Alternatively, start Workflow Monitor Agent using the Server Manager command-line interface 5/5 Select custom Workflow Monitor Agent component definition Include parameter for the Group Name for this Workflow Monitor Agent
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.