Bug 748393

Summary: Unable to get query results in multithreaded mode
Product: [JBoss] JBoss Enterprise BRMS Platform 5 Reporter: Tomas Schlosser <tschloss>
Component: BRE (Expert, Fusion)Assignee: Mark Proctor <mproctor>
Status: CLOSED WONTFIX QA Contact: Tomas Schlosser <tschloss>
Severity: medium Docs Contact:
Priority: unspecified    
Version: BRMS 5.3.0.GACC: brms-jira, lpetrovi, mproctor
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-03-20 17:02: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:
Attachments:
Description Flags
Simple reproducer none

Description Tomas Schlosser 2011-10-24 10:47:10 UTC
Created attachment 529782 [details]
Simple reproducer

Description of problem:
When using multithreaded evaluation I can't get query results.

Version-Release number of selected component (if applicable):
BRMS-5.2.0.GA

How reproducible:
Every time.

Steps to Reproduce:
1. Run the attached reproducer
  
Actual results:
*******************************************************************************************************
Partition task manager caught an unexpected exception: null
Drools is capturing the exception to avoid thread death. Please report stack trace to development team.
java.lang.NullPointerException
	at org.drools.base.org.drools.base.DroolsQuery783328245$getName.getValue(Unknown Source)
	at org.drools.base.ClassFieldReader.getValue(ClassFieldReader.java:86)
	at org.drools.base.evaluators.EqualityEvaluatorsDefinition$StringEqualEvaluator.evaluate(EqualityEvaluatorsDefinition.java:1881)
	at org.drools.rule.LiteralRestriction.isAllowed(LiteralRestriction.java:87)
	at org.drools.rule.LiteralConstraint.isAllowed(LiteralConstraint.java:109)
	at org.drools.reteoo.AlphaNode.assertObject(AlphaNode.java:130)
	at org.drools.reteoo.PartitionTaskManager$FactAssertAction.execute(PartitionTaskManager.java:272)
	at org.drools.reteoo.PartitionTaskManager$PartitionTask.run(PartitionTaskManager.java:116)
	at org.drools.concurrent.ExternalExecutorService$ObservableRunnable.run(ExternalExecutorService.java:443)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
	at java.lang.Thread.run(Thread.java:679)

Expected results:
Query results are retrieved and application ends correctly.

Additional info:
If you remove the rule "print event" from drl file, it all goes well. However if you remove the rule and fact inserting you get the same exception.

Comment 2 Lukáš Petrovický 2012-03-20 17:02:18 UTC
Multi-threaded evaluation was disabled and will be no longer maintained.