[rules-users] How to add more knowledge to Stateful session, post start-up

john.shepherdson at bt.com john.shepherdson at bt.com
Thu Mar 26 08:18:47 EDT 2009


At present I set up a ksession like this:

KnowledgeBase kbase = < call method that loads several rule files and
process flow files via
kbase.addKnowledgePackages(kbuilder.getKnowledgePackages()) >

StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession();

Then I set globals, start one of the processes, assert facts, fire rules
etc etc

Later on rules fire that start some or all of the remaining pre-loaded
processes, as required

Is the best way to do it? Instead should I be loading additional rule
and/or process files in to the ksession on the fly, rather than at the
beginning, for performance/scalability reasons? (I couldn't work out how
to do this without overwriting ksession).

Thanks in anticipation,

John Shepherdson

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20090326/8c88b289/attachment.html 


More information about the rules-users mailing list