Could you please share the unit test?
Thanks
Davide
On 02/27/2014 11:42 AM, Brecht De Rooms wrote:
Dear Drools users,
I just merged all my code to Drools 6.0.1 and I am happy to see that it is
more stable. Several issues I had with 5.6.x do not present themselves in
6.0.1. I am still stuck on one bug however that occurs randomly. I wrote a
unit test in which I deploy new rules and then call scanNow. Often the
unit test succeeds, but sometimes it throws this nullpointer exception.
java.lang.NullPointerException
at
org.drools.core.rule.Package.getRulesGeneratedFromResource(Package.java:668)
at
org.drools.core.rule.Package.removeRulesGeneratedFromResource(Package.java:658)
at
org.drools.core.reteoo.ReteooRuleBase.removeObjectsGeneratedFromResource(ReteooRuleBase.java:1653)
at
org.drools.compiler.compiler.PackageBuilder.removeObjectsGeneratedFromResource(PackageBuilder.java:4150)
at
org.drools.compiler.kie.builder.impl.KieContainerImpl.updateToVersion(KieContainerImpl.java:149)
at
org.kie.scanner.KieRepositoryScannerImpl.updateKieModule(KieRepositoryScannerImpl.java:214)
at
org.kie.scanner.KieRepositoryScannerImpl.scanNow(KieRepositoryScannerImpl.java:204)
at derooms.be.engine.RuleEngine.scanNow(RuleEngine.java:111)
at
derooms.be.engine.ruleDeployment.RulesPackageWriter.deployRules(RulesPackageWriter.java:104)
at
derooms.be.engine.ruleDeployment.RulesPackageWriter.addRules(RulesPackageWriter.java:84)
at
derooms.be.engine.dynamicRuleWatcher.RuleFileHandler.handleModifiedFile(RuleFileHandler.java:50)
at
derooms.be.engine.dynamicRuleWatcher.RulesWatcherRunnable.run(RulesWatcherRunnable.java:105)
at java.lang.Thread.run(Thread.java:744)
Does anyone have an idea what the problem might be?
Kind Regards,
Brecht
-------------------------------------------------------------
Brecht De Rooms
Phd Student @ WISE
Department of Computer Science
Vrije Universiteit Brussel
Pleinlaan 2, B-1050 Brussels, Belgium
office: 10 G 731f
phone: +32 2 629 37 49
email: bderooms(a)vub.ac.be
-------------------------------------------------------------
---
Dit e-mailbericht bevat geen virussen en malware omdat avast! Antivirus-bescherming
actief is.
http://www.avast.com
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users