Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1271534

Summary: drools-compiler fails to report error for invalid rule with field binding
Product: [Retired] JBoss BRMS Platform 6 Reporter: Hisao Furuichi <hfuruich>
Component: BREAssignee: Mario Fusco <mfusco>
Status: CLOSED EOL QA Contact: Tibor Zimanyi <tzimanyi>
Severity: high Docs Contact:
Priority: high    
Version: 6.1.0CC: etirelli, lpetrovi
Target Milestone: ER5   
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:08:47 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
pojo which contains Message class
none
sample drl as reproducer none

Description Hisao Furuichi 2015-10-14 08:42:50 UTC
Created attachment 1082744 [details]
pojo which contains Message class

Description of problem:
Validation on business-central does not alert drl error which BRMS 5.3.1 and JBDS 8.1 does.

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

Steps to Reproduce:
Please proceed all of instructions on business-central 
1: upload the attached reproducer-0.0.1-SNAPSHOT.jar into artifact repository
2: create a new project
3: set project's dependency to reproducer-0.0.1-SNAPSHOT.jar
3: create a new package "com.sample"
4: create a new drl which looks like attached reproducer.drl
5: click validate

Actual results:
Although attribute of Message, "bra", is not defined in the Class, validation does not alert any error. 

Expected results:
Validate fails.

Additional info:
With JBoss developer Studio 8.1, following error message will be displayed on the console:
===
BuildError: Unable to create Field Extractor for 'bra'Field/method 'bra' not found for class 'com.sample$Message'
Sample.drl	/reproducerProject/src/main/resources/rules  line 7  Drools Error
===
Also with guvnor comes with BRMS 5.3.1, validation works as expected too.

Comment 1 Hisao Furuichi 2015-10-14 08:44:01 UTC
Created attachment 1082746 [details]
sample drl as reproducer

Comment 4 Edson Tirelli 2015-10-22 17:59:37 UTC
For completeness, here is the cherry-pick on 6.3.x branch:

https://github.com/droolsjbpm/drools/commit/59a304aee6ec3ca835457a1a654bebfcf2f7b929

Comment 5 Tibor Zimanyi 2015-11-11 16:26:58 UTC
Verified in 6.2.0.ER5. The verification fails. Also the new test created by mentioned commit passes.

Comment 6 Tibor Zimanyi 2015-11-11 16:30:47 UTC
Sorry for confusion. I meant the validation fails. From the "steps to reproduce."