[jboss-jira] [JBoss JIRA] (DROOLS-634) Exception thrown from WorkingMemoryLogger randomly when simultaneous evaluation taking place by different threads
Anantjot Anand (JIRA)
issues at jboss.org
Thu Dec 11 10:33:29 EST 2014
[ https://issues.jboss.org/browse/DROOLS-634?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13027122#comment-13027122 ]
Anantjot Anand commented on DROOLS-634:
---------------------------------------
In my case, we were providing the runtime model+rules to another team who was incorporating jars in to their flow. I believed they had flaw in their singleton approach when loading rulebase. The webservices environment bring this type of issue to forefront when one thread is still loading rulebase and building link lists and other data structures for managing rule network and a separate thread comes along prematurely to do the evaluation.
I added a null pointer check at the point of exception and asked them to double check their singleton approach. They came back that my fix resolved this but I believe fixing the singleton had solved the issue for them.
> Exception thrown from WorkingMemoryLogger randomly when simultaneous evaluation taking place by different threads
> -----------------------------------------------------------------------------------------------------------------
>
> Key: DROOLS-634
> URL: https://issues.jboss.org/browse/DROOLS-634
> Project: Drools
> Issue Type: Bug
> Affects Versions: 6.2.0.CR1
> Reporter: Anantjot Anand
> Assignee: Mario Fusco
>
> Caused by: java.lang.NullPointerException
> at org.drools.core.reteoo.RuleTerminalNodeLeftTuple.getDeclarationIds(RuleTerminalNodeLeftTuple.java:394)
> at org.drools.core.audit.WorkingMemoryLogger.extractDeclarations(WorkingMemoryLogger.java:325)
> at org.drools.core.audit.WorkingMemoryLogger.matchCreated(WorkingMemoryLogger.java:269)
> at org.drools.core.event.AgendaEventSupport.fireActivationCreated(AgendaEventSupport.java:58)
> at org.drools.core.phreak.PhreakRuleTerminalNode.doLeftTupleInsert(PhreakRuleTerminalNode.java:95)
> at org.drools.core.phreak.PhreakRuleTerminalNode.doLeftInserts(PhreakRuleTerminalNode.java:69)
> at org.drools.core.phreak.PhreakRuleTerminalNode.doNode(PhreakRuleTerminalNode.java:42)
> at org.drools.core.phreak.RuleNetworkEvaluator.innerEval(RuleNetworkEvaluator.java:316)
> at org.drools.core.phreak.RuleNetworkEvaluator.outerEval(RuleNetworkEvaluator.java:161)
> at org.drools.core.phreak.RuleNetworkEvaluator.evaluateNetwork(RuleNetworkEvaluator.java:116)
> at org.drools.core.phreak.RuleExecutor.reEvaluateNetwork(RuleExecutor.java:225)
> at org.drools.core.phreak.RuleExecutor.evaluateNetworkAndFire(RuleExecutor.java:98)
> at org.drools.core.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:988)
> at org.drools.core.common.DefaultAgenda.fireAllRules(DefaultAgenda.java:1274)
> at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1281)
> at org.drools.core.impl.StatefulKnowledgeSessionImpl.fireAllRules(StatefulKnowledgeSessionImpl.java:1254)
--
This message was sent by Atlassian JIRA
(v6.3.11#6341)
More information about the jboss-jira
mailing list