Debug a rulebase

Debug a rulebase

When writing rules it is important that they are thoroughly tested to ensure they operate in the intended way. The Oracle Policy Modeling debugger is a tool that can be used to perform this testing function.

What do you want to do?

Use the integrated debugger to test the rules

Use the standalone debugger to test the rules

Use the integrated debugger to test the rules

To start debugging your rules using the integrated debugger:

  1. In Oracle Policy Modeling, select Build | Build and Debug.
  2. In the Debug Options dialog box, select the option to debug Without screens. (NOTE: This option will just test the logic of your rules. Testing with screens is covered separately in Test an interview or screen flow.) Click OK.

 

The debugger will open with the Debug view in the top right hand pane in Oracle Policy Modeling.

On the left hand side of the Data view is a tree view of the entity instances and relationships in the build model.

 

 

The icons used in this pane, and what they represent, are given below:

Global entity
Containment relationship
Entity instance
Reference relationship
Inferred relationship

 

The right hand side of the Data view shows either an attribute list, or a relationship editor, depending on what item you have selected in the left hand pane.

 

You can also start a debugger session from within the Build Model. To do this:

  1. In Oracle Policy Modeling, select View | Build Model.
  2. Select the attribute that you would like to investigate, right-click and select Investigate in Debugger.
  3. In the Debug Options dialog box, select the option to debug Without screens. Click OK.

The Debugger will open to the Decision view which will show all the relevant paths for a goal simultaneously.

Using the standalone debugger to test the rules

To start debugging your rules using the standalone debugger:

  1. Go to Start | All Programs | Oracle | Tools | Oracle Policy Modeling Debugger.
    The standalone Debugger will open.
  2. SelectFile | Debug Compiled Rulebase.
  3. Browse to select your compiled rulebase (XML) file (this is typically located in the output folder of your rulebase project). Click Open.

On the right hand side of the Data view in the Debugger you will see the attributes in your rulebase.

 

See also: