[jboss-jira] [JBoss JIRA] (DROOLS-1711) Jitting process may randomly fail during multithreaded execution

Mario Fusco (JIRA) issues at jboss.org
Wed Aug 23 10:38:00 EDT 2017


Mario Fusco created DROOLS-1711:
-----------------------------------

             Summary: Jitting process may randomly fail during multithreaded execution
                 Key: DROOLS-1711
                 URL: https://issues.jboss.org/browse/DROOLS-1711
             Project: Drools
          Issue Type: Bug
          Components: core engine
            Reporter: Mario Fusco
            Assignee: Mario Fusco


The jitting process assumes that the mvel constraint has been evaluated at least once before it kicks in. This may not be the case during a multithreaded execution (especially when running with many threads and a very low jitting threshold) because the jitting process may start when other threads have already requested the constraint evaluation using the mvel interpreted constraint (thus incrementing the jitting counter) but none of them had enough time to complete it. When this happens the jitting process trying to work on an uncompleted AST throwing internally an exception like the following:

{code}
Exception in thread "drools-worker-1" java.lang.RuntimeException: java.lang.RuntimeException: Null accessor on node: firings
	at org.drools.core.rule.constraint.MvelConstraint.executeJitting(MvelConstraint.java:346)
	at org.drools.core.rule.constraint.MvelConstraint.access$200(MvelConstraint.java:82)
	at org.drools.core.rule.constraint.MvelConstraint$ConditionJitter.run(MvelConstraint.java:313)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.RuntimeException: Null accessor on node: firings
	at org.drools.core.rule.constraint.ConditionAnalyzer.analyzeNode(ConditionAnalyzer.java:302)
	at org.drools.core.rule.constraint.ConditionAnalyzer.analyzeSingleCondition(ConditionAnalyzer.java:159)
	at org.drools.core.rule.constraint.ConditionAnalyzer.analyzeCondition(ConditionAnalyzer.java:138)
	at org.drools.core.rule.constraint.ConditionAnalyzer.analyzeCondition(ConditionAnalyzer.java:109)
	at org.drools.core.rule.constraint.MvelConditionEvaluator.getAnalyzedCondition(MvelConditionEvaluator.java:129)
	at org.drools.core.rule.constraint.MvelConstraint.executeJitting(MvelConstraint.java:333)
	... 5 more
{code}



--
This message was sent by Atlassian JIRA
(v7.2.3#72005)


More information about the jboss-jira mailing list