Bug 1001752

Summary: Using no-loop attribute in guided editor can have surprising result
Product: [Retired] JBoss BRMS Platform 6 Reporter: Jiri Locker <jlocker>
Component: Business CentralAssignee: manstis
Status: CLOSED CURRENTRELEASE QA Contact: Jiri Locker <jlocker>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.0.0   
Target Milestone: ER4   
Target Release: 6.0.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-08-06 20:15:18 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Jiri Locker 2013-08-27 16:27:41 UTC
Description of problem:
When no-loop attribute is added its value checkbox is unchecked (meaning false), however the DRL source contains only "no-loop" without any value, which has the same meaning as "no-loop true". After saving the rule (without touching the no-loop checkbox and leaving it in its default unchecked state) and reopening it, the checkbox is checked. That is consistent with the .rdrl file content, however slightly surprising.

Version-Release number of selected component (if applicable):
ER1

How reproducible:
-

Steps to Reproduce:
1. create a new Guided rule
2. add no-loop attribute
3. save the rule, close it and reopen

Actual results:
no-loop checkbox is unchecked after step 2 and checked after step 3.

Expected results:
no-loop checkbox should be checked after adding the attribute.

Additional info:
no-loop defaults to "false" (when the attribute is completely omitted). When the user is adding it to the rule it's probably in order to set it to "true", therefore it makes sense to default to "true" after adding the attribute. The only error is that it's checkbox state doesn't reflect this.

Comment 2 manstis 2013-09-06 16:37:25 UTC
If the user as explicitly added the no-loop attribute I've made it so the DRL renders "no-loop false" or "no-loop true". Not rendering the attribute at all could confuse the user (and means when we unmarshall from DRL the "no-loop" attribute would be missing all together if it wasn't in the DRL).