[rules-users] Batch processing large volume of Same type Of Facts

Stephen Masters stephen.masters at me.com
Fri Feb 7 13:25:25 EST 2014


Depending on your rules, you should be able to insert large numbers of facts and then fire all rules.

Note that it’s worth testing the optimal number to insert each time. I have previously found it faster to insert in batches, rather than hundreds. Partly because of the smaller memory footprint if I remember right. i.e. Inserting 1000 facts and then firing rules would cause me to hit GC limits in the JVM, whereas, inserting 100 at a time kept the memory footprint lower, so it turned out to be quicker. All depends on your own rules though.


On 7 Feb 2014, at 17:16, mattmadhavan <mmadhavan at facs.org> wrote:

> Hello,
> I have millions of the same type of Facts which are read from the Datebase. 
> The rules will go through each fact and produce an Array of derived records
> from the FACT.
> 
> Do I need to process one FACT at a time or can I pass in say 500 FACTS at a
> time? I am using Stateless Session for this purpose.
> 
> Can some one suggest me some ideas please?
> 
> 
> I appreciate in advance!
> 
> Thanks
> Matt'M 
> 
> 
> 
> --
> View this message in context: http://drools.46999.n3.nabble.com/Batch-processing-large-volume-of-Same-type-Of-Facts-tp4028014.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