Oracle Workflow
Oracle Workflow
Business processes today involve getting many types of information to multiple people according to rules that are constantly changing. Oracle Workflow lets you automate and continuously improve business processes, routing information of any type according to business rules you can easily change to people both inside and outside your enterprise. See: Major Features and Definitions. Routing Information With so much information available, and in so many different forms, how do you get the right information to the right people? Oracle Workflow lets you provide each person with all the information they need to take action. Oracle Workflow can route supporting information to each decision maker in a business process. Defining and Modifying Business Rules Oracle Workflow lets you define and continuously improve your business processes using a drag-and-drop process designer. Unlike workflow systems that simply route documents from one user to another with some approval steps, Oracle Workflow lets you model sophisticated business processes. You can define processes that loop, branch into parallel flows and then rendezvous, decompose into subflows, and more. Because Oracle Workflow can decide which path to take based on the result of a stored procedure, you can use the full power of PL/SQL, the language of the Oracle database server, to express any business rule that affects a workflow process. See: Workflow Processes. Delivering Electronic Notifications Oracle Workflow extends the reach of business process automation throughout the enterprise and beyond to include any e-mail or Internet user. Oracle Workflow lets people receive notifications of items awaiting their attention via e-mail, and act based on their e-mail responses. You can even view your list of things to do, including necessary supporting information, and take action using a standard Web browser. Integrating Systems Oracle Workflow lets you set up subscriptions to business events which can launch workflows or enable messages to be propagated from one system to another when business events occur. You can communicate events among systems within your own enterprise and with external systems as well. In this way, you can implement point-topoint messaging integration or use Oracle Workflow as a messaging hub for more complex system integration scenarios. You can model business processes that include complex routing and processing rules to handle events powerfully and flexibly.
Oracle Workflow lets you include your own PL/SQL procedures or external functions as activities in your workflows. Without modifying your application code, you can have your own program run whenever the Workflow Engine detects that your program's prerequisites are satisfied. Electronic Notifications Oracle Workflow lets you include users in your workflows to handle activities that cannot be automated, such as approvals for requisitions or sales orders. Electronic notifications are routed to a role, which can be an individual user or a group of users. Any user associated with that role can act on the notification. Each notification includes a message that contains all the information a user needs to make a decision. The information may be embedded in the message body or attached as a separate document. Oracle Workflow interprets each notification activity response to decide how to move on to the next workflow activity. Electronic Mail Integration Electronic mail (e-mail) users can receive notifications of outstanding work items and can respond to those notifications using their e-mail application of choice. An e-mail notification can include an attachment that provides another means of responding to the notification. Internet-Enabled Workflow Any user with access to a standard Web browser can be included in a workflow. Web users can access a Notification Web page to see their outstanding work items, then navigate to additional pages to see more details or provide a response. Monitoring and Administration Workflow administrators and users can view the progress of a work item in a workflow process by connecting to the Workflow Monitor using a standard Web browser that supports Java. The Workflow Monitor displays an annotated view of the process diagram for a particular instance of a workflow process, so that users can get a graphical depiction of their work item status. The Workflow Monitor also displays a separate status summary for the work item, the process, and each activity in the process. If you are using the version of Oracle Workflow embedded in Oracle Applications and you have implemented Oracle Applications Manager, you can also use the Oracle Workflow Manager component of Oracle Applications Manager as an additional administration tool for Oracle Workflow. Oracle Applications Manager is a tool that provides administrative and diagnostic capabilities for concurrent processing, Oracle Workflow, and other functionality in Oracle Applications. For more information, please refer to the Oracle Applications Manager online help. Also, if you are using the standalone version of Oracle Workflow available with Oracle9i Release 2, you can use the standalone Oracle Workflow Manager component available through Oracle Enterprise Manager as an additional administration tool for
Oracle Workflow. For more information, please refer to the Oracle Workflow Manager online help.
Workflow Processes
Oracle Workflow manages business processes according to rules that you define. The rules, which we call a workflow process definition, include the activities that occur in the process and the relationship between those activities. An activity in a process definition can be an automated function defined by a PL/SQL stored procedure or an external function, a notification to a user or role that may optionally request a response, a business event, or a subflow that itself is made up of a more granular set of activities. A workflow process is initiated when an application calls a set of Oracle Workflow Engine APIs. The Workflow Engine takes over by driving the relevant work item defined by the application, through a specific workflow process definition. According to the workflow process definition, the Workflow Engine performs automated steps and invokes appropriate agents when external processing is required. The following diagram depicts a simplified workflow process definition that routes a requisition to a manager or set of managers for approval.
We refer to the whole drawing as a process or process diagram. The icons represent activities, and the arrows represent the transitions between the activities. In the above example, new items are created for the process when a user creates and submits a requisition in the appropriate application.
This process contains several workflow activities implemented as PL/SQL stored procedures, including: Select Approver--to select, according to your business rules, who should approve the requisition.
Verify Authority--to verify that a selected approver has the spending authority to approve the requisition.
Step 1 Partitioning Workflow Tables Partitioning addresses key issues in supporting very large tables and indexes by letting you decompose them into smaller and more manageable pieces called partitions. SQL queries and DML statements do not need to be modified in order to access partitioned tables. However, once partitions are defined, DDL statements can access and manipulate individual partitions rather than entire tables or indexes. In this way, partitioning can simplify the manageability of large database objects. Also, partitioning is entirely transparent to applications. You can optionally run a script to partition certain Workflow tables that store runtime status data. For the version of Oracle Workflow embedded in Oracle Applications, the script is called wfupartb.sql; for the standalone version of Oracle Workflow, the script is called wfupart.sql. This step is highly recommended for performance gain. The script partitions four Workflow tables and recreates the associated indexes. The following table shows the Workflow tables and indexes on which the script runs. Table WF_ITEM_ACTIVITY_STATUSES Index WF_ITEM_ACTIVITY_STATUSES_PK WF_ITEM_ACTIVITY_STATUSES_N1 WF_ITEM_ACTIVITY_STATUSES_N2 WF_ITEM_ACTIVITY_STATUSES_H WF_ITEM_ACTIVITY_STATUSES_H_N1 WF_ITEM_ACTIVITY_STATUSES_H_N2 WF_ITEM_ATTRIBUTE_VALUES WF_ITEMS WF_ITEM_ATTRIBUTE_VALUES_PK WF_ITEMS_PK WF_ITEMS_N1 WF_ITEMS_N2 WF_ITEMS_N3
Before running the partitioning script, you should back up these four tables so that you can restore them in case the script fails. To run the script, you must have sufficient free space on the table and index tablespaces. During the creation of the partitioned tables, the script requires slightly
more diskspace than the underlying tables, in the same tablespace where the underlying tables are located. Similarly, sufficient free space is required for the index tablespace. Additionally, you should allow sufficient time for the script to run. The amount of time needed depends on the amount of data in the tables. When the tables already contain existing data, such as after an upgrade from a previous release, the script requires more time than it does when the tables are empty, such as after a fresh installation of Oracle Workflow. To minimize the time required, run the script as early as possible in your setup process. Attention: If you are running the partitioning script through Oracle Net Services, then you must set the TWO_TASK variable before you begin. For Oracle Workflow embedded in Oracle Applications, the wfupartb.sql script is located in the admin/sql subdirectory under $FND_TOP. Use the script as follows:
sqlplus <apps_user>/<apps_passwd> @wfupartb <fnd_user> <fnd_passwd> <apps_user> <apps_passwd>
For example:
sqlplus apps/apps @wfupartb applsys apps apps apps
For standalone Oracle Workflow, the wfupart.sql script is located in the wf/admin/sql subdirectory in your Oracle Home. Use the script as follows:
sqlplus <wf_user>/<wf_passwd> @wfupart <wf_user> <wf_passwd>
For example:
sqlplus owf_mgr/owf_mgr @wfupart owf_mgr owf_mgr
If the partitioning script fails, you must perform any necessary cleanup manually. Since the script's operations are DDL operations running in nologging mode, rollback is not possible. Context: You need to perform this step only once.
. Note: A workflow process definition can also be stored as a flat file, which can be opened and edited in a text editor so that the process definition can be spoken by a screen reader for greater user accessibility. Note: If you maximize the Navigator window or any process window in Oracle Workflow Builder, you will not be able to access the menu from your keyboard using the Alt key.
Processes--lists the process activities or workflow process definitions for the current item type. See: Process Window and Activities.
Notifications--lists the notification activities associated with the current item type. A notification activity sends a message to a user or role. The message may prompt for a response or may simply provide information. See: Activities.
Functions--lists the function activities associated with the current item type. A function activity represents a PL/SQL stored procedure that the Workflow Engine executes automatically. A function activity can also have activity attributes associated with it. See: Activities.
Events--lists the event activities associated with the current item type. An event activity represents a business event that the process receives, raises, or sends. See: Activities.
Messages--lists the messages that a notification activity associated with the current item type can send to a user or role. A message can have message attributes associated with it. See: Messages.
Lookup Types--lists the lookup types associated with the current item type. A lookup type has one or more values called lookup codes associated with it. A lookup type is a list of values that can be referenced by a message, or by a notification, function, or process as its possible result type. See: Lookup Types.
Note: Each data store also contains a Directory Service branch. The Directory Service branch lists all the directory service roles that you load from your Oracle Workflow database. See: Roles. If the data store is a database connection and the database contains other item types that you have not loaded into Oracle Workflow Builder, a branch called Hidden Item Types appears. When you double-click on Hidden Item Types, you get a Show Item Types window that lets you load other item types into Oracle Workflow Builder. Before using Oracle Workflow Builder, you should plan what your process needs to accomplish. In particular, determine what activities need to occur, the order of the activities, what results dictate the different branches of the process, who needs to be informed and what they need to know. Oracle Workflow provides several demonstration workflow examples. See: Sample Workflow Processes. There are several ways you can go about creating a workflow process definition: Top-Down Design--If you prefer to approach your design from a high level, you can first sketching out the process diagram with activities, then go back later to create the supporting objects for each activity. See: To Create a Process Definition from Top-Down.
Bottom-Up Design--If you prefer to take a more programmatic approach to your design, you can first define each of the supporting objects of your process before attempting to create a higher level process diagram. See: To Create a Process Definition From Bottom-Up.