Release Notes 6.2.3 (Jan-2013)

OpenRules® Release 6.2.3 adds new features such as generation of decision execution reports in the HTML format, an ability to create more compact decision tables by utilizing new decision templates, advanced interfaces for external rules, and more.

Decision Execution Reports

OpenRules® 6.2.3 provides an ability to generate decision execution reports in the HTML-format. To generate an execution report, you should add the following setting to the decision’s Java launcher:

decision.put("report", "On");

before calling decision.execute(). By default, execution reports are not generated.

OpenRules® automatically creates a sub-directory “report” in your main project directory and places several html-files (one per decision table) inside this sub-directory. For every decision table, including single-hit, multi-hit, and rule sequencing tables, OpenRules® generates a separate html-file with the name Report<n>.<DecisionTableName>.html, where n is an execution order number for this particular decision table. For example, for the sample project “DecisionLoan” OpenRules® will generate the following files:

where the first report file Report.<decision-name> contains hyperlinks to all other reports (read more at the User Manual, p. 33). These reports help a rule designer to analyze which rules were actually executed and in which order.

Similarly, Rule Solver™ now produces its own execution report in the HTML format. See an example of a RuleSolverReport.html produced for the same decision “DecisionLoan” but executed in the OPENRULES_MODE equal to "Solve".

Compacting Large Decisions Tables

When your decision table contains too many columns it may become too wide and unmanageable. To make your decision table more compact, OpenRules® 6.2.3 allows you to move a variable name from the column title to the rule cells. To do that, instead of the standard column’s structure"Condition" with two sub-columns you may use another column representation "ConditionVarOperValue" with 3 sub-columns:

This way you may place condition on different variables in the same column as on the picture below:

Similarly, instead of a column of the type “Conclusion” you may use a column of the type “ConclusionVarOperValue”. You may read more at the User Manual p. 25.

Referencing to Arrays of Values inside Decision Table Cells

Instead of listing arrays of values through commas, inside decision table cells you define such arrays as Data tables (with an ability to chose them using Excel's ranges) and then refer to them using the  ArrayString's method "join" like in the following example:

where the array "products1" is defined in the table similar to this one:

The complete example can be found in the sample project "DecisionUpSell".

Using External Rules with Decision Templates

We extended the standard interface for the External Rules to work with decision templates. You may define which conditions and actions from the standard "DecisionTableExecuteTemplates.xls" you want to use in you decision tables like in the following example:

ExternalRules externalRules = new ExternalRules();


     "DefineGreeting",    //table name

     "DecisionTable1Template", //template name

     new String[] { "If", "If", "Then" }, // labels

     new String[] { "Current Hour", "Current Hour", "Result" }, // descriptions/variables

     new String[][] {     //rules

         new String[] {">=0","<=11","Good Morning"},

         new String[] {">=12","<=17","Good Afternoon"},

         new String[] {">=18","<=21","Good Evening"},

         new String[] {">=22","<=24","Good Night"}



This way you may dynamically create decision table from your database. In this case you may define a glossary based on your variable names as defined in your database, e.g: 

     decision.getGlossary().put("Current Hour", "Request", "hour");

     decision.getGlossary().put("Result", "Response", "result");

 A complete example can be found in the new sample project "DecisionExternalRules".

Adding Rule Numbering Column to the Standard Decision Templates

Many customers prefer to start their decision tables with a column "#" that contains their own numbers for all rules. So, now you do not have to create a custom template and simply use the first column of the predefined type "C#". It is especially useful when you want to merge some values in the very first condition column that is prohibited by OpenRules. Adding an additional column with rule numbers allows you to go around of this known implementation restriction.

The product documentation has been properly updated. As always, the new release remains backward compatible. After downloading the latest OpenRules® release 6.2.3 from here, you need to update the following files:

- all openrules.config/*.xls files in "openrules.config" or in your own repository

- openrules.all.jar in "openrules.config/lib".

Please post your comments and suggestions to the Google Discussion Group or send them to