skip to main content
Corticon Studio: Rule Modeling Guide : Troubleshooting Rulesheets and Ruleflows : Using Corticon Studio to reproduce the behavior : Running a Ruletest in Corticon Studio
 

Try Corticon Now
Running a Ruletest in Corticon Studio
When you run a Corticon Ruletest, it might produce error messages in Corticon Studio. Error messages are distinct from Post messages you specified in Rulesheet Rule Statements to generate info, warning, and violation statements that are posted by normal operation of the rules.
*If you encounter any of the following errors, take the actions described in that section. It may be possible, using these techniques, to work around a problem by identifying the expression syntax that produces it, and trying to express the logic in a different way. The Corticon Rule Language is very flexible and usually allows the same logic to be expressed in many different ways.
*If you do not encounter any of these errors, proceed to the Analyzing Test Results section.

The Constraint Violation

Figure 251. A Constraint Violation in a Ruletest
A constraint violation indicates that values in test attributes are not within numeric constraint ranges or not included in enumerated lists that have been set in the Vocabulary's Custom Data Types. In the following example, the constraint is shown, and its violation is marked on the attribute and its entity in the Input column:
Running the test halts at the first constraint violation. The log lists the first constraint exception and its detailed trace. No response is generated.
You can revise the input to have valid values, or choose to relax enforcement of such violations through a setting in the Corticon brms.properties file, com.corticon.vocabulary.cdt.relaxEnforcement=true.
When the option is enabled, a response is generated that includes each of constraint violation warnings. For example:
<CorticonResponse xmlns="urn:Corticon"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
decisionServiceName="Cargo.ers_null_ALL">
<WorkDocuments>
<Cargo id="Cargo_id_1">
<weight>0</weight>
<volume>-1</volume>
<container>standard</container>
</Cargo>
</WorkDocuments>
<Messages version="0.0">
<Message postOrder="cc00000001">
<severity>Warning</severity>
<text>constraint violation setting Cargo.weight to value [0]</text>
<entityReference href="Cargo_id_1" />
</Message>
<Message postOrder="cc00000002">
<severity>Warning</severity>
<text>constraint violation setting Cargo.container to value [secure]</text>
<entityReference href="Cargo_id_1" />
</Message>
<Message postOrder="cc00000003">
<severity>Warning</severity>
<text>constraint violation setting Cargo.volume to value [-1]</text>
<entityReference href="Cargo_id_1" />
</Message>
<Message postOrder="cc00000004">
<severity>Info</severity>
<text>[1] Cargo weighing <= 20,000 kilos must be packaged in a standard container.</text>
<entityReference href="Cargo_id_1" />
</Message>
</Messages>
</CorticonResponse>
See Relaxing enforcement of Custom Data Types for details about constraints and the option to relax enforcement.
Note: The output example shown reflects the execution properties in a Ruletest output file. If you extract the same response for a Ruletest from your Studio log when the RULETRACE logging filter is enabled, you would see several additional execution properties such as inputTransients, returnTransients, invokedByTester, inBytes, newOrModified, manuallyCreated, dataSource, new_or_modified_attributes, new_or_modified_association_ids. These properties can be helpful in support efforts but they are otherwise not meaningful to users and should never be included in requests (and will not be in responses) other than the logs of those run as Ruletests. When you export files through the Rulesheet > Testsheet > Data commands, these internal properties are removed.

The Null Pointer Exception

Figure 252. A Null Pointer Exception as Shown in a Ruletest
A null pointer exception (NPE) almost always indicates a problem with the rule engine, whether it is being employed by the Corticon Studio or by Corticon Server. If you encounter this error, contact Technical Support, and set aside copies of the Vocabulary, Rulesheet, and Ruletest so we can use them for further troubleshooting.

The Reactor Exception

Figure 253. The Reactor Exception Window
This error is also indicative of a possible rule engine problem, but it may also indicate improper or unnecessarily complex language usage in your rule expressions. The Rule Language's flexibility may permit workarounds to the limitation(s) that produced this message; Progress Corticon Technical Support should be contacted for further assistance. As with the NPE errors, please save copies of the Vocabulary, Rulesheet, and Ruletest for use by Progress Corticon Support staff.

The Fatal Exception

On very rare occasions, you may experience a full crash of the Corticon Studio application. In these cases, you will see a window like the following:
Figure 254. The Fatal Error Window
This type of problem can only be resolved by Corticon. But before contacting Progress Corticon Technical Support, click on the button, which will display a window with more information about the cause of the error, as shown below:
Figure 255. The Fatal Error Details Window
Click the Copy button (as shown) and paste the text into a text file. Send us this text file along with the standard set of Corticon Studio files (Vocabulary, Rulesheet, Ruletest) when you report this problem.