Bug 1264321

Summary: Guided rule editor: replace or replaceAll condition parameters on a String missing on reopening a guided rule
Product: [Retired] JBoss BRMS Platform 6 Reporter: Suresh Pritmani <spritman>
Component: Business CentralAssignee: manstis
Status: CLOSED EOL QA Contact: Jiri Locker <jlocker>
Severity: unspecified Docs Contact:
Priority: high    
Version: 6.1.0CC: kverlaen
Target Milestone: ER4   
Target Release: 6.2.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-03-27 19:09:56 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:
Embargoed:
Attachments:
Description Flags
Document contains screenshots and steps to reproduce the issue.
none
Project repository which contains guided rule - "ReplaceIssue" - as a reproducer.
none
Component/Fact jar which is being used with the attached reproducer project. none

Description Suresh Pritmani 2015-09-18 08:14:17 UTC
Created attachment 1074712 [details]
Document contains screenshots and steps to reproduce the issue.

Description of problem:
In Guided Rule Editor, customer is trying to add expression for variables (String type) using replace or replaceAll condition parameters. 

After saving, closing and reopening same rule in guided rule editor, string expressions are missing.

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

How reproducible:

Steps to Reproduce:
1. Create a Project using Business Central and import the fact which contains string variable.

2. Create one Guided Rule by using that imported Fact

3. Use the fact and String variable of that fact. (as per attached project, used TestVO)

4. Apply replace condition on the string variable with some expression and rule looks like below:

~~~
import com.org.redhat.TestVO;

rule "Replace_condition_Issue"
     dialect "mvel"
     when
          TestVO( $cts : test.replace("+",""))
     then
end
~~~

5. Save the guided rule, close it and try to reopen same rule.

6. Expressions from replace condition has been removed.

Actual results:

There should be no change in the rule while reopening it. It should be as it is with whatever parameters have been configured in replace condition.

Expected results:

After reopening the rule in guided rule editor, expressions from replace condition has been removed.

Additional info:

I have attached Document which contains screen shots and all steps to reproduce the issue.

Comment 1 Suresh Pritmani 2015-09-18 08:19:03 UTC
Created attachment 1074713 [details]
Project repository which contains guided rule - "ReplaceIssue" - as a reproducer.

Comment 2 Suresh Pritmani 2015-09-18 08:19:59 UTC
Created attachment 1074715 [details]
Component/Fact jar which is being used with the attached reproducer project.