Without seeing your full code I suspect you have more than one Customer in Working Memory.<br><br>From what you have provided message &quot;Electric Service Interfaces are required&quot; can only be thrown by one rule, that has only one condition - checking a Customer object. Also message &quot;PAN Device list cannot be null or empty&quot; is thrown from a rule that also checks Customer (however the additional constraints may lead to only two messages being reported). I also assume you don&#39;t do anything extra in your error handler (such as updating facts).<br>
<br><div class="gmail_quote">On 15 December 2011 15:33, Venkat <span dir="ltr">&lt;<a href="mailto:ven12344@yahoo.com">ven12344@yahoo.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi Manstis, I have tried what you said and found that, in the drools rule<br>
file the fields and objects were not able to get by its direct name, so I<br>
called those by calling from get methods and I am able to run the rules but<br>
it is behaving odd now.<br>
<br>
I mean it is giving me the same error in my &quot;consequence&quot; many times and<br>
then going to the end rule and giving me the same error twice. So I don&#39;t<br>
know what is happening. Check out the response I get, also check the rule<br>
file for messages<br>
<div class="im"><br>
<br>
<br>
Customer and ServiceContext are both required<br>
</div><div class="im">Electric Service Interfaces are required<br>
Electric Service Interfaces are required<br>
Electric Service Interfaces are required<br>
Electric Service Interfaces are required<br>
</div>PAN Device list cannot be null or empty<br>
PAN Device list cannot be null or empty<br>
Exception executing predicate<br>
$panDevice.getSmartDeviceModel().getDeviceClass() == null<br>
com.ge.energy.drms.smartgrid.datamodel.services.enddevicemanagement.pandeviceregistrationservice.PANDeviceRegistrationServiceFault:<br>
Exception executing predicate<br>
$panDevice.getSmartDeviceModel().getDeviceClass() == null<br>
        at<br>
com.ge.energy.drms.external.integration.service.impl.PANDeviceRegistrationServiceImpl.provisionPANDevice(PANDeviceRegistrationServiceImpl.java:100)<br>
<div><div class="h5">        at<br>
com.ge.energy.drms.external.integration.service.impl.test.ProvisionPanDeviceRequestValidationTest.testMACAdress(ProvisionPanDeviceRequestValidationTest.java:249)<br>
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br>
        at<br>
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)<br>
        at<br>
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)<br>
        at java.lang.reflect.Method.invoke(Method.java:597)<br>
        at junit.framework.TestCase.runTest(TestCase.java:168)<br>
        at junit.framework.TestCase.runBare(TestCase.java:134)<br>
        at junit.framework.TestResult$1.protect(TestResult.java:110)<br>
        at junit.framework.TestResult.runProtected(TestResult.java:128)<br>
        at junit.framework.TestResult.run(TestResult.java:113)<br>
        at junit.framework.TestCase.run(TestCase.java:124)<br>
        at junit.framework.TestSuite.runTest(TestSuite.java:232)<br>
        at junit.framework.TestSuite.run(TestSuite.java:227)<br>
        at<br>
org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)<br>
        at<br>
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)<br>
</div></div>com.ge.energy.drms.smartgrid.datamodel.services.enddevicemanagement.pandeviceregistrationservice.PANDeviceRegistrationServiceFault:<br>
Exception executing predicate<br>
$panDevice.getSmartDeviceModel().getDeviceClass() == null<br>
        at<br>
com.ge.energy.drms.external.integration.service.impl.PANDeviceRegistrationServiceImpl.provisionPANDevice(PANDeviceRegistrationServiceImpl.java:100)<br>
        at<br>
com.ge.energy.drms.external.integration.service.impl.test.ProvisionPanDeviceRequestValidationTest.testInstallCode(ProvisionPanDeviceRequestValidationTest.java:285)<br>
<div><div class="h5">        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br>
        at<br>
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)<br>
        at<br>
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)<br>
        at java.lang.reflect.Method.invoke(Method.java:597)<br>
        at junit.framework.TestCase.runTest(TestCase.java:168)<br>
        at junit.framework.TestCase.runBare(TestCase.java:134)<br>
        at junit.framework.TestResult$1.protect(TestResult.java:110)<br>
        at junit.framework.TestResult.runProtected(TestResult.java:128)<br>
        at junit.framework.TestResult.run(TestResult.java:113)<br>
        at junit.framework.TestCase.run(TestCase.java:124)<br>
        at junit.framework.TestSuite.runTest(TestSuite.java:232)<br>
        at junit.framework.TestSuite.run(TestSuite.java:227)<br>
        at<br>
org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)<br>
        at<br>
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)<br>
</div></div>com.ge.energy.drms.smartgrid.datamodel.services.enddevicemanagement.pandeviceregistrationservice.PANDeviceRegistrationServiceFault:<br>
Exception executing predicate<br>
$panDevice.getSmartDeviceModel().getDeviceClass() == null<br>
        at<br>
com.ge.energy.drms.external.integration.service.impl.PANDeviceRegistrationServiceImpl.provisionPANDevice(PANDeviceRegistrationServiceImpl.java:100)<br>
        at<br>
com.ge.energy.drms.external.integration.service.impl.test.ProvisionPanDeviceRequestValidationTest.testSmartDeviceModel(ProvisionPanDeviceRequestValidationTest.java:321)<br>
<div><div class="h5">        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br>
        at<br>
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)<br>
        at<br>
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)<br>
        at java.lang.reflect.Method.invoke(Method.java:597)<br>
        at junit.framework.TestCase.runTest(TestCase.java:168)<br>
        at junit.framework.TestCase.runBare(TestCase.java:134)<br>
        at junit.framework.TestResult$1.protect(TestResult.java:110)<br>
        at junit.framework.TestResult.runProtected(TestResult.java:128)<br>
        at junit.framework.TestResult.run(TestResult.java:113)<br>
        at junit.framework.TestCase.run(TestCase.java:124)<br>
        at junit.framework.TestSuite.runTest(TestSuite.java:232)<br>
        at junit.framework.TestSuite.run(TestSuite.java:227)<br>
        at<br>
org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)<br>
        at<br>
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)<br>
        at<br>
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)<br>
</div></div>Exception executing predicate<br>
$panDevice.getSmartDeviceModel().getDeviceClass() == null<br>
<div class="im">Device Type cannot be null<br>
Device Type cannot be null<br>
<br>
<br>
<br>
<br>
</div>Thanks<br>
<span class="HOEnZb"><font color="#888888">Venkat.<br>
<br>
--<br>
View this message in context: <a href="http://drools.46999.n3.nabble.com/Eval0Invoker-java-lang-NullPointerException-tp3586222p3588957.html" target="_blank">http://drools.46999.n3.nabble.com/Eval0Invoker-java-lang-NullPointerException-tp3586222p3588957.html</a><br>

</font></span><div class="HOEnZb"><div class="h5">Sent from the Drools: User forum mailing list archive at Nabble.com.<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</div></div></blockquote></div><br>