IBM BPM, V8.0.1, All platforms > Create processes in IBM Process Designer > Modeling processes > Building services > Building a Decision service

Adding a BAL Rule component to a service

The Business Action Language (BAL) Rule component provides a rule editor that allows rule designers to author business rules using natural language technology. Using natural language, instead of JavaScript, to author rules means that no programming expertise is required to create business rules, and the rules are easier for people to read and understand.

The following steps describe how to add a BAL Rule component to a sample Decision service. The purpose of the sample service is to determine whether approval is required for certain employee expenses. The sample service is a single-function Rule that can be called from any other service.


Procedure

  1. Open the process application that contains a business process definition.

  2. Create a Decision service as described in the related topic "Adding a Decision service to a process."

  3. In the diagram of the new Decision service, click BAL Rule in the component palette and drag the BAL Rule component icon from the palette to the service diagram.

  4. In the Properties tab, enter a name for the new BAL Rule component, such as ExpenseApproval.

  5. Click the Variables tab.

  6. Click Add Private to add a private variable to the Decision service. For this sample Decision service, add the private variable, request.

    1. Replace Untitled1 in the Name field with request .

    2. Click Select next to Variable Type and select the type from the list.

  7. If you use the Activity Wizard to create a Decision service, you can choose existing variables to add as input and output. You should use the Activity Wizard when you start with an existing activity and want to quickly create a service to implement the activity. To access the wizard, right-click an activity icon in a process diagram and select Activity Wizard from the list of options.

  8. Click Add Private.
  9. Replace Untitled1 in the Name field with approvalRequired .

  10. Click Select next to Variable Type and select the Boolean type from the list. The Boolean variable type is included in the IBM BPM System Data toolkit. The System Data toolkit is included in each process application by default.

  11. Click the Decisions tab to open the rules editor.


What to do next

Create a rule that is implemented for this Decision service. Refer to the related topic "Authoring rules using the BAL rule editor."

Building a Decision service


Related tasks:
Scenario: Creating a Decision service in a Personalized Notification process
Create a service
Declaring variables for a BPD or a service
Authoring rules using the BAL rule editor
Adding a Decision service to a process
Create rules using the rule editor