Hello there! I've just started with the BRMS (what an awesome feature I might add). So I've deployed a simple rule, packaged it and created a snapshot.<br><br>The package is created and when I access the url provided by the BRMS it tries to download the package, so I'm assuming it is published.<br>
<br>So I ran this code inside eclipse:<br><br>public static void main(String[] args) {<br> RuleAgent agent = RuleAgent.newRuleAgent("/MyRules.properties"); <br> RuleBase rb = agent.getRuleBase();<br>
StatefulSession session = rb.newStatefulSession();<br> Funcionario f = new Funcionario();<br> f.setSalario(1000.0);<br> Cargo c = new Cargo();<br> c.setDescricao("desenvolvedor");<br>
f.setCargo(c);<br> session.insert(c);<br> Decision d = new Decision();<br> session.insert(d);<br> session.fireAllRules();<br> session.dispose();<br> }<br clear="all"><br>---------------------MyRules.properties----------------------------<br>
<a href="http://localhost:8080/drools-jbrms/org.drools.brms.JBRMS/package/com.synos.rules.credito/production-1">http://localhost:8080/drools-jbrms/org.drools.brms.JBRMS/package/com.synos.rules.credito/production-1</a><br>
poll=10<br><br><br>It throws a nullpointer exception, as the agent.getRulebase() is returning a null object.<br><br>What am I missing here?<br><br>Best regards<br><br><br>-- <br>"In a world without fences and walls, who needs Gates and Windows?"