Hi Rod,
I had a similar error and I solved it by upgrading to Drools 4.0.3 on
the BRMS and for the RuleAgent.
See Jira:
http://jira.jboss.com/jira/browse/JBRULES-1245
Hope this helps,
Len
-----Original Message-----
From: rules-users-bounces(a)lists.jboss.org
[mailto:rules-users-bounces@lists.jboss.org] On Behalf Of
kissro(a)lidp.com
Sent: Friday, November 16, 2007 1:23 PM
To: rules-users(a)lists.jboss.org
Subject: [rules-users] Exception error when using RuleAgent
Hello,
I created a rule in BRMS and downloaded the package to a directory. I'm
using RuleAgent to load the RuleBase using the following code:
RuleAgent agent =
RuleAgent.newRuleAgent("/brmsunderwritingrules.properties");
RuleBase ruleBase = agent.getRuleBase();
I'm getting the following errors. Could someone tell me what I'm doing
wrong and/or how to fix this please.
ERROR [STDERR] RuleAgent(underwritingconfig) INFO
: Configuring with newInstance=true, secondsToRefresh=30
ERROR [STDERR] RuleAgent(underwritingconfig) INFO
: Configuring package provider : DirectoryScanner scanning
dir: \deployed\rules found 2 file(s).
ERROR [STDERR]
java.lang.ClassCastException:java.util.Collections$EmptyMap
ERROR [STDERR] at org.drools.rule.Package.readExternal
ERROR [STDERR] at
java.io.ObjectInputStream.readExternalData(ObjectInputStream.java:1753)
ERROR [STDERR] at
java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1711
)
ERROR [STDERR] at
java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1299)
ERROR [STDERR] at
java.io.ObjectInputStream.readObject(ObjectInputStream.java:339)
ERROR [STDERR] at
org.drools.agent.FileScanner.readPackage(FileScanner.java:109)
ERROR [STDERR] at
org.drools.agent.FileScanner.getChangeSet(FileScanner.java:79)
ERROR [STDERR] at
org.drools.agent.FileScanner.loadPackageChanges(FileScanner.java:57)
ERROR [STDERR] at
org.drools.agent.DirectoryScanner.loadPackageChanges(DirectoryScanner.ja
va:43)
ERROR [STDERR] at
org.drools.agent.RuleAgent.checkForChanges(RuleAgent.java:330)
ERROR [STDERR] at
org.drools.agent.RuleAgent.refreshRuleBase(RuleAgent.java:298)
ERROR [STDERR] at
org.drools.agent.RuleAgent.configure(RuleAgent.java:284)
ERROR [STDERR] at
org.drools.agent.RuleAgent.init(RuleAgent.java:208)
ERROR [STDERR] at
org.drools.agent.RuleAgent.newRuleAgent(RuleAgent.java:176)
ERROR [STDERR] at
org.drools.agent.RuleAgent.newRuleAgent(RuleAgent.java:148)
Thank You
Rod
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users