[
http://jira.jboss.com/jira/browse/JBRULES-798?page=all ]
Edson Tirelli resolved JBRULES-798.
-----------------------------------
Fix Version/s: 4.0.0.MR3
Resolution: Done
Problem fixed and unit tests added.
Thank you for reporting and let us know plz if you have any other problem.
CLONE -null pointer with number comparison..
--------------------------------------------
Key: JBRULES-798
URL:
http://jira.jboss.com/jira/browse/JBRULES-798
Project: JBoss Rules
Issue Type: Bug
Security Level: Public(Everyone can see)
Affects Versions: 3.0.5
Environment: Windows XP or Solaris
Sun JDK 1.4.2
Drools 3.0.4 distribution
Reporter: Sanjay Mahurpawar
Assigned To: Edson Tirelli
Fix For: 4.0.0.MR3
getting a null pointer while asserting fact:
Caused by: java.lang.NullPointerException
at org.drools.base.evaluators.IntegerFactory$IntegerGreaterEvaluator.evaluate(Unknown
Source)
at org.drools.rule.BoundVariableConstraint.isAllowed(Unknown Source)
at org.drools.common.BetaNodeBinder.isAllowed(Unknown Source)
at org.drools.reteoo.TupleSource.attemptJoin(Unknown Source)
at org.drools.reteoo.JoinNode.assertTuple(Unknown Source)
at org.drools.reteoo.LeftInputAdapterNode.createAndAssertTuple(Unknown Source)
at org.drools.reteoo.LeftInputAdapterNode.assertObject(Unknown Source)
at org.drools.reteoo.ObjectSource.propagateAssertObject(Unknown Source)
at org.drools.reteoo.ObjectTypeNode.assertObject(Unknown Source)
at org.drools.reteoo.Rete.assertObject(Unknown Source)
at org.drools.reteoo.ReteooRuleBase.assertObject(Unknown Source)
at org.drools.reteoo.ReteooWorkingMemory.doAssertObject(Unknown Source)
at org.drools.common.AbstractWorkingMemory.assertObject(Unknown Source)
at org.drools.common.AbstractWorkingMemory.assertObject(Unknown Source)
Rule is something like this:
rule "Greater Than with NULL number!!"
when
MyFact ( integerAttribute > 10 )
then
.....
end
the *intergerAttribute* is of type java.lang.Integer and value is *null*.
no such problem if expression changed to *integerAttribute == 10* or !=
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira