Creating Rules


Overview

Tasks

Included with

Tivoli Change Management administration

Overview

Creating business rules

Business rules (rules) enable you to embed the unique business practices of your company into the change management process. For example, if the policy of your company requires the controller to approve purchases over $5,000, you can create a rule that automatically adds the controller to the approval list. When a change is submitted that includes a purchase over $5,000, the controller is notified.

You can define the rules that fire against changes. Rules can invoke the following actions when fired:

  • Update specified text boxes associated with the change
  • Add approval requirements
  • Notify additional personnel
  • Add a task
  • Execute an operating system command

Rules fire when a user modifies the status of a change or are fired by the TCM Scheduler. See Firing Rules.

Note: Multiple business rules can fire against a single change. General rules fire first in ascending order, then by category rules in ascending order, both based on the rule ID. In addition, actions from earlier rules can affect the firing of later rules.

The Rule dialog box

You use the Rule dialog box to add, edit, or view a Rule.

The Rule dialog box contains these tabs:

Tab Function
General The General tab is where you specify common information such as:
  • Rule name
  • Change category for the rule
  • Rule description
  • Mode (test or live)
  • Firing time for time-dependent rules
  • Rule priority
  • Status type, if any, when the rule fires

See Creating a new rule.

Definition The Definition tab is where you define the rule criteria. See Defining rule criteria.
Actions The Actions tab is where you specify the events that occur when the rule fires. See Setting database field values, Adding approvers, Notifying additional personnel, Adding a task to a schedule, and Refusing an action.
Testing The Testing tab is where you specify whether the rule is in live or test mode. See Testing Rules.

To access the Rule dialog box, do one of the following:

  • In the Rules dialog box, choose Edit, Add, or View.
  • Result: The Rule dialog box appears.

Tasks

Creating a new rule

You can create rules that reflect the practices of your company. In this manner, you incorporate business practices into your change management process.

To create a new rule:

  1. From the Configuration menu, choose Work with Rules.
    Result: The Rules dialog box appears.
  2. In the Rules dialog box, choose Add.
    Result: The Rule dialog box appears.
  3. In the Name box, type a unique new name for the rule.
  4. Under Priority, type a number if you want a priority other than 1.
  5. Do one of the following:
    • If you are using Tivoli Change Management in Non-Secure Mode, go to step 6.
    • If you are using Tivoli Change Management in Secure Mode, go to step 7.
  6. Under Usage, do one of the following:
    • If you want the rule to fire against all changes, select All. Go to step 10.
    • If you want the rule to fire against only changes in a change category, select Category. Go to step 9.
  7. Under Usage, do one of the following:
    • If you want the rule to fire against only changes in an organization you support, select Organization Specific. Go to step 8.
    • If you want the rule to fire against only changes in a change category you support, select Category Specific. Go to step 9.
  8. Next to the Organization box, select an Organization. Go to step 9.
  9. Next to the Category box, choose the Browse button to select a change category for the rule.
  10. In the Description box, type a description of the rule.
    Note: The description becomes part of the notification message if the rule includes a notification. Type a message that accurately describes the rule.
  11. In the Message box, type a message that is sent to the user when the rule fires. If you do not want a message sent, delete the default message.
    Note: For rules with Refuse action, include information in your message so a user can understand the reason it was refused and then modify the transaction appropriately. See Refusing an action.
  12. Do one of the following:
    • To specify time-dependency for the rule, Select the Time Dependent check box and go to step 8.
    • If you do not want to specify time-dependency, go to step 11.
  13. Under Based On, select the option button that corresponds to the change event date to associate with the rule:
    • Date requested
    • Date needed by
    • Earliest date scheduled
    • Latest date scheduled
  14. In the Days box, type the number of days before or after the change event date for the rule to fire.
    Note: Type 0 (zero) in the Days box to fire the rule on the specified date.
  15. Under When, select Before or After to indicate whether the rule should fire before or after the selected date.
    Note:
    • If you typed 0 in the Days box, you can select either Before or After.
    • Time-dependent rules are executed by the TCM Scheduler. See Firing Rules.
  16. Under Mode, select either Live or Test.
  17. Under Firing Status, select one or more status types for the rule to fire.
  18. See Defining rule criteria to create a definition for the rule. You cannot save a rule until it is defined.
    Caution: Once you make a rule live and it fires against changes, you cannot automatically remove the effects of the rule. See Testing Rules.

Defining rule criteria

Rule criteria consist of a phrase or a series of phrases that you construct to define to which changes a rule applies. For example, you can create a rule that requires additional approvers for any high risk changes. To do so, you specify the criterion (Risk code = High) on the Definition tab.

You use two sections of the Definition tab to create rule criteria:

  • Create single phrases that define the rule in the Phrase section
  • Insert phrases into the Phrase Construction list

The Phrase Construction section displays the combined phrases. You can add operators and parentheses to connect the phrases. See Understanding Phrases.

To define rule criteria:

  1. From the Rule dialog box, choose the Definition tab.
    Result: The Definition tab appears.
  2. From the Table list, select a database table name.
  3. From the Attribute list, select the attribute to use in the rule.
    The Attribute list contains only the fields in the table you selected.
  4. From the Operator list, select an operator (<,>,=,>=, or <>).
  5. In the Value box, type a value to complete the phrase.
    Note: To indicate a null value, type the special value TCM_NULL in the Value box. Do not leave this box empty. If you use the Category attribute in one of the tables, you must type the category code, rather than the category description, in the Value box.
  6. Do one of the following:
    • If you are inserting the first phrase, choose Insert.
      Result: The phrase is added to the list.
    • If the list already contains a phrase, choose one of the three operator buttons (And, Or, or Not), then choose Insert.
      Result: When you choose an operator or choose Insert to insert an additional phrase, the new text is added to the end of the phrase construction.
  7. Do one of the following:
    • Define another phrase.
    • Choose OK to save the rule.
    • Select another tab of the dialog box to continue defining the rule.

Setting database field values

Tivoli Change Management can automatically update the contents of a specified database field for the records defined on the Definition tab when a rule is fired. For example, you might create a rule that sets the risk code for a change to HIGH when the estimated cost of a change exceeds a specified amount.

To specify a field setting:

  1. From the Rule dialog box, choose the Action tab.
    Result: The Actions tab appears.
  2. Under Action, select the Set Field option button.
    Note: Rule actions you specify using Set Field do not affect text fields in the Change dialog box, such as description and reason.
  3. From the Field list, select the name of the database field to set.
  4. In the Value box, type the value to set.
    Caution: If the value is defined elsewhere in the database, make sure you type it exactly as it is defined. For example, if you select the Category field, the value you type must be a valid change category code.
  5. Choose Insert.
    Result: The action is added to the Action table.
  6. Do one of the following:
    • Specify another action.
    • Choose OK to save the rule.
    • Select another tab of the dialog box to continue defining the rule.

Adding approvers

You can add additional approvers when a rule is fired. Additional approvers can be individuals or organizations.

To specify additional approvers:

  1. From the Rule dialog box, choose the Actions tab.
    Result: The Actions tab appears.
  2. Under Action, select Add Approver.
  3. Choose the Browse button next to the Name box to display the Approver dialog box.
  4. Under Type, select the option that corresponds to the type of approver you want to add. Choose OK.
    Result: The Person or the Organization Manager dialog box appears.
  5. Select the user or organization to add as an approver, then choose OK.
    Result: The Actions tab of the Rule dialog box appears.
  6. Choose Insert.
    Result: The approver is added to the Actions table.
  7. Choose Set Priority.
    Result: The Set Approval Priority dialog box appears.
  8. In the Priority box, type the approval priority to assign to the approver.
  9. Choose OK.
    Result: The Rule dialog box appears.
  10. Do one of the following:
    • Specify another action.
    • Choose OK to save the rule.
    • Select another tab of the dialog box to continue defining the rule.

Notifying additional personnel

Tivoli Change Management automatically sends notifications to the person assigned to a change to keep him or her informed of the approval status. Also, approvers are notified when the change requires an approval decision. You can add a rule to configure the Notification Monitor to notify additional people when a rule is fired.

To specify additional notifications:

  1. From the Rule dialog box, choose the Actions tab.
    Result: The Actions tab appears.
  2. Under Action, select Notify.
  3. Next to the Name box, choose the Browse button to display the Notification dialog box.
    Result: The Notification dialog box appears.
  4. Under Type, select the option button that corresponds to the type of notification you want to add.
  5. Choose OK.
    Result: The following occur:
    If you chose ... then ...
    Person or CCB the Person or Add CCB dialog box appears.
    Select the user or CCB you want notified and choose OK.
    Result: The Actions tab of the Rule dialog box appears. Go to step 7.
    Organization the Organization box appears. Select the organization you want notified and choose OK.
    Result: A Question appears.
  1. Do one of the following:
    Choose this button ... to ...
    Yes notify all members of the organization.
    Result: The organization name and (All) appears in the Name box.
    No notify only titleholders of the organization.
  1. Choose Insert.
    Result: The notification is added to the Actions table.
  2. Do one of the following:
    • Specify another action.
    • Choose OK to save the rule.
    • Select another tab of the dialog box to continue defining the rule.

    Note: All members of a CCB receive a notification.

Adding a task

You can add a task to be performed when a rule is fired.

To add a task:

  1. From the Rule dialog box, choose the Actions tab.
    Result:The Actions tab appears.
  2. Under Action, select Add Task.
  3. In the Task box, type a name for the task.
  4. In the Duration box, type a value representing the allotted duration of the task.
    Note: The value represents the number of days.
  5. In the Hours box, type the expected number of labor hours for the task.
  6. Choose Insert.
    Result: The task is added to the Actions table.
  7. Do one of the following:
    • Specify another action.
    • Choose OK to save the rule.
    • Select another tab of the dialog box to continue defining the rule.

Executing an operating system command

Tivoli Change Management can execute an operating system command when a rule is fired. For example, a rule can execute a command to distribute software downloads or patches across a network. You might do this when changes involving upgrades are complete.

To have a rule execute an operating system command:

  1. From the Rule dialog box, choose the Actions tab.
    Result:The Actions tab appears.
  2. Under Action, select Call.
  3. Under Call, from the Command list, select the command to call.
    The command must have already been set up from the Commands tab of the Tivoli Change Management List Maintenance dialog box.
    Note: Commands executed by rules that are not time-dependent run on the computer system of the user. Commands executed by time-dependent rules run on the system where the TCM Scheduler runs.
  4. Choose Insert.
    Result: The command is added to the Actions table.
  5. Do one of the following:
    • Specify another action.
    • Choose OK to save the rule.
    • Select another tab of the dialog box to continue defining the rule.
Refusing an action Refusing an action prevents the transaction that fired the rule from occurring if the Refuse rule condition evaluates to true. If the Refuse rule condition evaluates to true, for example, the following occur:
  • The dialog box where a user initiated the transaction and caused the Refuse rule to fire is displayed.
  • The Refuse rule message is displayed.
  • The change record is reset to its original state before the transaction was initiated, including resetting any Set Field action defined for the rule or any other rule that fired before the rule with the Refuse action.
  • Any other actions included in the rule are ignored.

To add a Refuse action:

  1. From the Rule dialog box, choose the Actions tab.
    Result:The Actions tab appears.
  2. Under Action, select Refuse.
    Note: To ensure that a Refuse action is processed first, set the rule priority value to the smallest value for its change category. Frequently, this is 0.
  3. Choose Insert.
    Result: The Refuse action is added to the Actions table
  4. Do one of the following:
    • Specify another action.
    • Choose OK to save the rule.
    • Select another tab of the dialog box to continue defining the rule.