Bug 724474 (BRMS-419)

Summary: Business Rule elements containing a fact that has been removed cannot be edited (in Guided editor)
Product: [JBoss] JBoss Enterprise BRMS Platform 5 Reporter: Jiri Locker <jlocker>
Component: BRM (Guvnor)Assignee: manstis
Status: VERIFIED --- QA Contact: Jiri Locker <jlocker>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.1.0.ER2, 5.1.0.ER3, 5.1.0.ER4CC: atangrin, lpetrovi, manstis
Target Milestone: ER3   
Target Release: BRMS 5.3.1 GA   
Hardware: Unspecified   
OS: Unspecified   
URL: http://jira.jboss.org/jira/browse/BRMS-419
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Previously, when a fact within the Business Rule element was removed, the rule could no longer be edited within the Guided Rule Editor. The particular section of the Guided Rule Editor that used that fact type would freeze and prevent editing. This has been resolved by allowing frozen sections to be deleted and recreated.
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-10-28 23:18:13 UTC Type: Feature Request
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Attachments:
Description Flags
OutdatedRule.png none

Description Jiri Locker 2010-10-27 15:24:33 UTC
securitylevel_name: Public

Let's have a package with a few imported types, one of them be "Fact", and a Business Rule created in Guided editor that uses "Fact" in the WHEN or THEN section. After removing "Fact" from imported types, saving package configuration and reopening the rule, each element of the rule, that contains the removed "Fact" becomes inactive and cannot be edited/removed (until re-importing the missing fact).

Comment 1 Jiri Locker 2010-10-27 15:25:55 UTC
Attachment: Added: OutdatedRule.png


Comment 2 Jiri Locker 2010-10-27 15:29:32 UTC
Link: Added: This issue is related to GUVNOR-364


Comment 3 Tihomir Surdilovic 2010-10-28 23:17:35 UTC
This is done by design. To the rule it's irrelevant if a fact has been removed, or is not part of the used working set. Either way it knows that it cannot get to the fact type used so it disables that part of the rule from being editable. 

How would you have it behave differently (please reopen jira with description)


Comment 4 Tihomir Surdilovic 2010-10-28 23:18:13 UTC
Done by design. Unless we have a better way of dealing with this I will place jira as resolved.

Comment 5 Jiri Locker 2010-11-08 17:57:09 UTC
I find it perfectly reasonable to not be able to edit a part of a rule if the fact that is used in it is no longer accessible. But it makes no sense to me that I can't remove the part of the rule that has no effect without making that fact available again. If the user doesn't have access to the fact any more, the disabled snippet will hang there forever (unless they make up a workaround).

So, making the snippet disabled AND adding an enabled Remove button would make it perfect IMO. What do you think?

Comment 6 Jiri Locker 2011-05-06 22:05:43 UTC
Link: Added: This issue depends GUVNOR-1360


Comment 7 Lukáš Petrovický 2011-11-01 10:43:14 UTC
The related JIRA suggests this should be fixed already.

Comment 8 manstis 2012-09-28 12:12:38 UTC
Fixed as part of https://bugzilla.redhat.com/show_bug.cgi?id=851100 (which was a BRMS 5.3.1+ blocker+)

Comment 9 Anne-Louise Tangring 2012-10-01 15:26:11 UTC
If this was fixed in another BZ, shouldn't this be closed as a dup?

Comment 10 manstis 2012-10-01 15:41:12 UTC
No. This is not a duplicate issue, but the fix for the other BZ also fixed this one. So, 2 bugs, 1 fix. Different bugs.

Comment 11 Jiri Locker 2012-10-05 14:47:13 UTC
Hello Michael, the issue is fixed partially. Frozen rule elements under THEN section still cannot be removed. Please make them removable too. WHEN section looks good, thanks.

Comment 12 manstis 2012-10-05 15:18:49 UTC
Sorry I missed the RHS. Change made and pushed to github https://github.com/droolsjbpm/guvnor/commit/9b19a881c4ffc53044ef5a875db5d0c06c726941

Comment 13 Jiri Locker 2012-10-11 14:16:18 UTC
Fix verified in BRMS 5.3.0.ER3.

Comment 14 Jiri Locker 2012-10-11 14:30:03 UTC
Correction: verified in BRMS 5.3.1.

Comment 15 Douglas Hoffman 2012-10-18 01:29:52 UTC
Hey Mike, 

It is not clear to me whether the work-around is still necessary. Do customers still need to delete and recreate the rule? Or is this no longer necessary?

Also, thank you for the release notes text.

-Doug

Comment 16 manstis 2012-10-18 08:06:26 UTC
(In reply to comment #15)
> Hey Mike, 
> 
> It is not clear to me whether the work-around is still necessary. Do
> customers still need to delete and recreate the rule? Or is this no longer
> necessary?
> 
> Also, thank you for the release notes text.
> 
> -Doug

Hi Doug,

I've updated the release notes: the workaround is no longer required.

Comment 17 Douglas Hoffman 2012-10-19 00:28:36 UTC
Thanks for the update, Mike.

I'll add those changes to the Release Notes.

- Doug