[rules-users] How to add rules to working memory during livetime?

Mark Proctor mproctor at codehaus.org
Sat Jan 10 13:11:50 EST 2009


Trägenap wrote:
> Hi,
>
> I want to add a new rule to an existing workingmemory. I not want to 
> loose the "situation" in this workingmemory.
>
> First I create a new workingmemory and insert a couple of facts.
> After firingAllRules it could be possible to add some new rules (load 
> some new drl-files) to the existing workingmemory without loosing the 
> facts inside this.
>
> Is this possible?
>
> First idea was to retrieve all facts from the workingmemory, create a 
> new one including the new rules and insert all facts again?
> Is this the correct way?
no that's wrong. just add the rules to an existing rulebase that has 
working memories. the working memories are attached the rulebase and 
will receive the updates without losing any exisitng state.

Mark
>
> Thanks
> Thorsten
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>
>





More information about the rules-users mailing list