Business rules

For ease in changing existing business needs, WebSphere Business Integration Server Express provides "business rule" capability. Business rules allow you to alter run-time behavior flexibly without having to redefine and redeploy the collaboration template. You can add, delete, or modify business rules without affecting the execution of other components.

For example, a business requirement might be to apply a 20% discount promotion for a season or to upgrade customer membership for purchases more than $300 in a promotional period. In these cases, modifying the collaboration template would be rather cumbersome. However, you can use business rules to adjust your business process to accommodate these new business requirements easily.

The following sections explain the use of business rules to meet your business requirements:

For more information about using New Business Rule Wizard, see the System Implementation Guide. For more information about viewing and managing business rules using System Monitor, see the System Administration Guide.

Business object probes and business rules

With the business rule capability, business object probes enable the business rule engine to monitor business object data for possible rule detection. The business rule engine processes the event if it determines that any rules are associated with the business object probe. For information on other functions of the business object probe, see Using business object probes .

For example, Scenario 2 below describes a situation in which a user wants to detect the accumulated purchase amount of a customer. Because this information is stored as an attribute in the Customer business object, the system monitors the attribute and executes the rule when the business condition is met. The business object probe provides the ideal solution for defining the specific point at which the business data is monitored for a business rule. See Scenario 2: Applying business rules using business object probes.

Overview of steps for using business object probes with business rules

Perform the following steps to define business object probes for use with business rules:

  1. Decide that business probes will monitor certain business object attributes for the business rule.
  2. Determine where in the Activity Diagram the business data will be monitored (for example, after a certain action node in a collaboration template).
  3. In Process Designer Express, define the business probes at the transition links in the collaboration template.
  4. In System Manager, create a collaboration based on the template. For information on using System Manager, see the System Administration Guide.
  5. In New Business Rule Wizard, walk through the steps to define the rule-specific information by using the business probes defined earlier. For information on using New Business Rule Wizard, see the System Implementation Guide.
  6. Deploy the new business rule to WebSphere Business Integration Server Express.

Examples of using business rules

The following examples illustrate the user's role in adding certain business logic to the WebSphere Business Integration Server Express. These examples illustrate the steps in defining the business logic and implementing the business rules.

Scenario 1: Applying a business rule at a designated time

In this scenario, your retail company has a new business requirement to apply a 20% promotional discount at the beginning of the Christmas shopping season. The following conditions exist in the WebSphere Business Integration Server Express project:

Perform the following steps to apply the discount for the specified time:

  1. Open System Manager, where the OrderProcessing collaboration is stored. For information on using System Manager, see the System Administration Guide.
  2. Invoke New Business Rule Wizard to begin creating a business rule. For information on using New Business Rule Wizard, see the System Implementation Guide.
  3. Walk through the steps in New Business Rule Wizard to define the rule-specific information (for example, new discount rate = 20%, rule apply time = December 1, 2004, 24:00).
  4. Save the new business rule to the project in WebSphere Business Integration Server Express.
  5. Deploy the new business rule to WebSphere Business Integration Server Express.

Result: The server updates the rule engine with the new rule definition and stores the rule in the server repository.

At the time designated in the business rule, the collaboration OrderProcessing executes. The customer receives a discount of 20%.

Scenario 2: Applying business rules using business object probes

In this scenario, your company runs a promotion to upgrade any customer to Gold membership if the customer's accumulated orders for a season exceed $300. The following conditions exist in the WebSphere Business Integration Server Express project:

Perform the following steps to upgrade the membership of any customer whose purchases exceed $300 for the season:

  1. Define a business probe in the collaboration template PurchaseOrderProcessing so that each time the system processes a purchase order, the business probe monitors the customer's purchase amount.
  2. Save the collaboration template.
  3. Open System Manager. For information on using System Manager, see the System Administration Guide.
  4. Invoke New Business Rule Wizard to begin creating a new business rule. For information on using New Business Rule Wizard, see the System Implementation Guide.
  5. Walk through the steps in New Business Rule Wizard to define the rule-specific information: the condition that total amount of purchases is greater than $300, the business probe to monitor, and the rule action to upgrade membership.
  6. Save the new business rule to the project in WebSphere Business Integration Server Express.
  7. Deploy the new business rule to WebSphere Business Integration Server Express.

Result: The server updates the rule engine with the new rule definition and stores the rule in the server repository.

The OrderProcessing collaboration processes the customer's orders as usual. When the business rule condition that the purchases exceed $300 is met, the UpgradeMember collaboration promotes the customer to Gold status.

Copyright IBM Corp. 2004, 2005