Event Delivery Network EDN Tuning About Oracle Business Process Management Tuning Oracle Workspace and Worklist Applications

Oracle Business Process Management Tuning 15-5 Bytes Max 800 MB Message Max 1000000 ■ MeasurementTopicConnectionFactory Send Timeout 240000 ■ BPMJMSServer MessageBuffer Size 100000 Note that the BPMJMSServer uses a Paging File and JMSFileStore.

15.4.2 Tuning Process Cubes

Process Cubes perform periodic aggregations to compute workload information. The frequency of these computations is determined by the CubeUpdateFrequency parameter of BPMNConfig mbean and can be changed from the Oracle Enterprise Manager console. In a high volume environment, consider changing this parameter to an appropriately higher value such as 12 hours, for example, to conserve computing resources. Process Cube Aggregator uses the BPM_CUBE_AUDITINSTANCE table to compute workload and performance information. Unwanted records from the BPM_CUBE_ AUDITINSTANCE table get purged as part of the SOA Purge script. Additionally, consider running the following delete script periodically to purge the unwanted records from BPM_CUBE_AUDITINSTANCE table for improving the performance of Process Cube computations. DELETE FROM BPM_CUBE_AUDITINSTANCE A WHERE EXISTS SELECT 1 FROM BPM_CUBE_AUDITINSTANCE B WHERE A.COMPONENTINSTANCEID = B.COMPONENTINSTANCEID AND B.OPERATION=INSTANCE_CREATED AND B.ACTIVITYSTATUS=PROCESSED 15-6 Oracle Fusion Middleware Performance and Tuning Guide 16 Oracle Human Workflow Performance Tuning 16-1 16 Oracle Human Workflow Performance Tuning This chapter describes how to tune Oracle Human Workflow for optimal performance. You can tune Oracle Human Workflow in these areas: ■ Section 16.1, About Oracle Human Workflow ■ Section 16.2, Basic Tuning Considerations ■ Section 16.3, Improving Server Performance ■ Section 16.4, Completing Workflows Faster ■ Section 16.5, Tuning Identity Provider ■ Section 16.6, Tuning the Database

16.1 About Oracle Human Workflow

Oracle Human Workflow is a service engine running in Oracle SOA Service Infrastructure that allows the execution of interactive human driven processes. A human workflow provides the human interaction support such as approve, reject, and reassign actions within a process or outside of any process. The Human Workflow service consists of a number of services that handle various aspects of human interaction with a business process. For more information, see Using the Human Workflow Service Component in Oracle Fusion Middleware Developers Guide for Oracle SOA Suite. See also the Oracle Human Workflow web site at http:www.oracle.comtechnologyproductssoahwindex.html.

16.2 Basic Tuning Considerations

This section discusses the various options available to address performance issues: ■ Minimize Client Response Time ■ Choose the Right Workflow Service Client ■ Narrow Qualifying Tasks Using Precise Filters ■ Retrieve Subset of Qualifying Tasks Paging ■ Fetch Only the Information That Is Needed for a Qualifying Task ■ Reduce the Number of Return Query Columns ■ Use the Aggregate API for Charting Task Statistics 16-2 Oracle Fusion Middleware Performance and Tuning Guide ■ Use the Count API Methods for Counting the Number of Tasks ■ Create Indexes On Demand for Flexfields ■ Use the doesTaskExist Method

16.2.1 Minimize Client Response Time

Since workflow client applications are interactive, it is important to have good response time at the client. Some of the factors that affect the response time include service call performance impacts, querying time to determine the set of qualifying tasks for the request, and the amount of additional information to be retrieved for each qualifying task.

16.2.2 Choose the Right Workflow Service Client

Workflow services support two major types of clients: SOAP and EJB clients. EJB clients can be further separated into local EJB clients and remote EJB clients. If the client application is based on .Net technologies, then only the SOAP workflow services can be used. However, if the client application is based on Java EE technology, then consider which client should be used based on your use case scenarios. The options are listed below: ■ Remote client - This is the best option in terms of performance in most cases. If the client is running in the same JVM as the workflow services soa-infra application, the API calls are optimized so that there is no remote method invocation RMI involved. If the client is on a different JVM, then RMI is used, which can impact performance due to the serialization and de-serialization of data between the API methods. ■ SOAP client - While this option is preferred for standardization based on web services, there are additional performance considerations when compared to the remote method invocation RMI used in the remote client. Additional processing is performed by the web-services technology stack which causes the marshalling and unmarshalling of API method arguments between XML. For more information, see Oracle Fusion Middleware Developers Guide for Oracle SOA Suite.

16.2.3 Narrow Qualifying Tasks Using Precise Filters

Using precise filters is one of the most important factors in improving response time. When a task list is retrieved, the query should be as precise as possible so the maximum filtering can be done at the database level. For example, when the inbox view is requested for a user, the tasks are filtered mainly based on whether they are assigned to the current user or to the groups the user belongs to. By specifying additional predicate filters on the inbox view, the overall response time for the query can be reduced since lesser number of tasks qualify. Alternatively, you can define views by specifying predicate filters and the overall response time for such views is reduced since lesser number of tasks qualify. All predicates passed to the query APIs or defined in the views are directly pushed to the database level SQL queries. With this information, the database optimizer can use the best indexes to create an optimal execution plan. The additional filters can be based on task attributes or promoted flex fields. For example, instead of listing all PO approval tasks, views can be defined to present tasks to the user based on priority, date, category, or amount range. Oracle Human Workflow Performance Tuning 16-3 Example: To retrieve all assigned tasks for a user with priority = 1, you can use the following API call: Predicate pred = new PredicateTableConstants.WFTASK_STATE_COLUMN, Predicate.OP_EQ, IWorkflowConstants.TASK_STATE_ASSIGNED; pred.addClausePredicate.AND, TableConstants.WFTASK_PRIORITY_COLUMN, Predicate.OP_EQ, 1; List tasks = querySvc.queryTasksctx, queryColumns, null, ITaskQueryService.AssignmentFilter.MY ITaskQueryService.AssignmentFilter.MY, null, pred, null, startRow, endRow;

16.2.4 Retrieve Subset of Qualifying Tasks Paging

Once the task list has been narrowed down to meet a specific criteria as discussed in the previous section, the next level of filtering is based on how many tasks are to be presented to the user. You want to avoid fetching too many rows, which not only increases the query time but also increases the application process time and the amount of data returned to client. The query API has paging parameters that control the number of qualifying rows returned to the user and the start row. For example, in the queryTasks method: List tasks = querySvc.queryTasksctx, queryColumns, null, ITaskQueryService.AssignmentFilter.MY, null, pred, null, startRow, endRow; Consider setting the startRow and endRow parameters to values that may limit the number of return matching records.

16.2.5 Fetch Only the Information That Is Needed for a Qualifying Task

When using the queryTask service, consider reducing the amount of optional information retrieved for each task returned in the list. This may reduce the performance impacts from additional SQL query and Java logic. For example, in the following queryTasks method, only the group actions information is retrieved. You can also retrieve attachment and payload information directly in the listing, but you may encounter performance impacts. ListITaskQueryService.OptionalInfo optionalInfo = new ArrayListITaskQueryService.OptionalInfo; optionalInfo.addITaskQueryService.OptionalInfo.GROUP_ACTIONS; optionalInfo.addITaskQueryService.OptionalInfo.ATTACHMENTS; optionalInfo.addITaskQueryService.OptionalInfo.PAYLOAD; List tasks = querySvc.queryTasksctx, queryColumns,