[rules-users] Identical Facts over rules, results being cached?

Wolfgang Laun wolfgang.laun at gmail.com
Wed Apr 9 05:16:29 EDT 2014


If it's general enough, it is not something to be shrugged off as "not
that hard".

You'll have to keep the fact and memorize all rules it fires, and
create a mechanism that'll let you call right hand sides when the
duplicate fact
arrives and with all variables bound to the same values. Huh!

-W

On 09/04/2014, Esteban Aliverti <esteban.aliverti at gmail.com> wrote:
> The question here is: what is the result of fireAllRules()? Caching the
> result of this method is trivial: it's just a number! I think that what you
> need to build is your own ad-hoc cache that knows how to extract a 'result'
> out of the session an keep it handy. Implementing this mechanism shouldn't
> be that hard (at least for simple - no nested- Facts) and once you have it
> you can validate the benefits.
>
> Regards,
>
>
> XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
>
> Esteban Aliverti
> - Blog @ http://ilesteban.wordpress.com
>
>
> On Wed, Apr 9, 2014 at 11:02 AM, Leonard93
> <leonardlindenau at hotmail.com>wrote:
>
>> Wouldn't that depend on how long the data is being kept and how often
>> identical rules are being fired?
>>
>> Or would you say the rule engine is faster than all the actions in
>> between
>> that it wouldnt matter?
>>
>>
>>
>> --
>> View this message in context:
>> http://drools.46999.n3.nabble.com/Identical-Facts-over-rules-results-being-cached-tp4029169p4029172.html
>> Sent from the Drools: User forum mailing list archive at Nabble.com.
>> _______________________________________________
>> 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