[
https://issues.jboss.org/browse/JBRULES-2734?page=com.atlassian.jira.plug...
]
Tommy Odom commented on JBRULES-2734:
-------------------------------------
I applied your change to 5.1.1 and verified that it fixes the problem for me, thanks!
NPE loading changeset
---------------------
Key: JBRULES-2734
URL:
https://issues.jboss.org/browse/JBRULES-2734
Project: Drools
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: drools-core (expert)
Affects Versions: 5.1.1.FINAL
Reporter: Tommy Odom
Assignee: Esteban Aliverti
Fix For: 5.2.0.CR1
We are receiving a NPE when drools is attempting to load the deltas from guvnor in our
webapp. This used to work fine in 5.0 but we recently upgraded to 5.1 and started
receiving this error after we create a new snapshot in guvnor.
The output from our application server log is:
KnowledgeAgent applying ChangeSet
KnowledgeAgent performing an incremental build of the ChangeSet
no visitor implementation for : class org.drools.ruleflow.core.RuleFlowProcess :
org.drools.ruleflow.core.RuleFlowProcess@30012e
Exception in thread "Thread-36"
org.drools.RuntimeDroolsException: java.lang.reflect.InvocationTargetException : [R
ule name=Project Part Custom Finishing Cost, agendaGroup=MAIN, salience=0, no-loop=false]
at org.drools.core.util.ReflectiveVisitor.visit(ReflectiveVisitor.java:56)
at
org.drools.agent.impl.BinaryResourceDiffProducerImpl.diff(BinaryResourceDiffProducerImpl.java:63)
at
org.drools.agent.impl.KnowledgeAgentImpl.incrementalBuildResources(KnowledgeAgentImpl.java:785)
at
org.drools.agent.impl.KnowledgeAgentImpl.buildKnowledgeBase(KnowledgeAgentImpl.java:586)
at
org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:185)
at
org.drools.agent.impl.KnowledgeAgentImpl$ChangeSetNotificationDetector.run(KnowledgeAgentImpl.java:1106)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597) at
org.drools.core.util.ReflectiveVisitor.visit(ReflectiveVisitor.java:47)
... 6 more
Caused by: java.lang.NullPointerException at
org.drools.rule.EvalCondition.equals(EvalCondition.java:169)
at org.drools.rule.GroupElement.equals(GroupElement.java:273)
at
org.drools.agent.impl.BinaryResourceDiffProducerImpl.compareRules(BinaryResourceDiffProducerImpl.java:258)
at
org.drools.agent.impl.BinaryResourceDiffProducerImpl.visitRule(BinaryResourceDiffProducerImpl.java:117)
... 11 more
The rule that it mentions in the error is:
dialect "java"
ruleflow-group "finishing-price"
when
$pp : ProjectPart(finishTime > 0)
eval(salesChannelId != 4 && includeFinishing)
then
double finishingRate = 1;
double customFinishingCost = $pp.getQuantity() * $pp.getFinishTime() * finishingRate;
addToProjectFinishingCost($pp.getProject(), customFinishingCost);
--
This message is automatically generated by JIRA.
For more information on JIRA, see:
http://www.atlassian.com/software/jira