Bug 1043395 - Invalid rules in jboss-bpm-example (Big App) - can't be opened/validated in Guider Rule Editor
Summary: Invalid rules in jboss-bpm-example (Big App) - can't be opened/validated in G...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss BPMS Platform 6
Classification: Retired
Component: Business Central
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: CR1
: 6.0.0
Assignee: Toni Rikkola
QA Contact: Jan Hrcek
URL:
Whiteboard:
: 1040037 (view as bug list)
Depends On: 1040037
Blocks: 1033590
TreeView+ depends on / blocked
 
Reported: 2013-12-16 08:26 UTC by Jan Hrcek
Modified: 2014-08-06 20:13 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2014-08-06 20:13:39 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Jan Hrcek 2013-12-16 08:26:13 UTC
Description of problem:
The guided rule definitions, that are part of jboss-bpm-example (Big App) should be reviewed. It should be possible to open each of them in Guider Rule Editor (GRE) and also to validate them successfully. However that is not the case. Currently there are the following issues:


1. Jumbo Mortgage - possible to open, but does not validate in GRE.
seems like the statement is not parsed correctly by the editor: application.setApr( application.getApr() + 0.5 );
--> We get the error:

Unable to Analyse Expression System.out.println("Executed Rule: " + drools.getRule().getName() ); application.setApr( );: [Error: unable to resolve method using strict-mode: com.redhat.bpms.examples.mortgage.Application.setApr()] [Near : {... application.setApr( ); ....}] ^ [Line: 3, Column: 0]


2. Rules 'Low down payment before appraisal' and 'Low down payment based on appaisal' do not even open in the editor

3. Rule 'Validate down payment' - rule is not parset correctly by GRE as you can see by checking the source tab. I believe it is caused by the syntax:
 Application( downPayment < 0  || > property.price ) which based on latest info from engineering might no longer be supported.

4. Rule 'Validate SSN' - same issue as in 3 (rule not parsed by GRE editor)


Version-Release number of selected component (if applicable):
BPMS 6.0.0 ER5

How reproducible:
Always

Steps to Reproduce:
1. Install the jboss-bpm-example (Big App)
2. In project explorer navigate to MortgageDemo application and try to open each of the guider rules and try to validate each of them

Actual results:
See details above -
1 rules does not validate (seems like it's not parsed correctly)
2 rules cannot be opened
2 rules are parsed incorrectly - they are not fully read in the G.R.Editor (recommendation do not use shorthand syntax for comparions)

Expected results:
It should be possible to open all rules and all of them should pass validation.

Comment 1 Kris Verlaenen 2013-12-17 02:36:27 UTC
Michael, could you assign this to someone?

Comment 2 manstis 2013-12-17 09:31:59 UTC
Sorry Toni, could you have a look please (it's possibly covered by one of the other Guided Rule Editor BZs)?

Comment 3 Toni Rikkola 2013-12-17 18:15:08 UTC
Unit test for the Jumbo Mortgage
https://github.com/droolsjbpm/drools/commit/c545fce01

Comment 4 Toni Rikkola 2013-12-17 18:37:08 UTC
Unit test for Validate down payment
https://github.com/droolsjbpm/drools/commit/cacb2fd6f

Comment 5 Toni Rikkola 2013-12-18 08:04:28 UTC
Giving this to Mario while he fixes the tests. The tests should fix everything except the field > 10 || < 1 issue. That must be just an issue with the example or possibly with an import tool that the rules were imported with.

Comment 6 Mario Fusco 2013-12-18 10:33:36 UTC
I fixed the drl unmarshalling issue related with the recognition of free form expression in rhs. Reassigning it to Toni.

Comment 7 Ryan Zhang 2014-01-07 09:36:05 UTC
*** Bug 1040037 has been marked as a duplicate of this bug. ***

Comment 8 Jan Hrcek 2014-01-09 13:44:42 UTC
As mentioned in Comment 5, the rules 'Validate down payment' and  'Validate SSN' will need to be updated in the BigApp repository to no longer use the abbreviated syntax, so that they can be correctly loaded by Guided Rule Editor.

Comment 10 Jan Hrcek 2014-01-22 06:35:22 UTC
Ok, verified with BPMS 6.0.0 CR1


Note You need to log in before you can comment on or make changes to this bug.