We have over 15,000 rows in the database and we need to apply the rules on this data. We are thinking of doing the following.

a.       Read the data from the database in batches

b.      Create beans for the data that we just read

c.       Run the rules on the beans (this results in setting some attributes on the bean)

d.      Save the beans back to the database

 

As you can see, there is some overhead in reading the data from the database, performing the OR mappings, and writing the data back to the database. Is there a way to avoid some of these steps? Can you please suggest some techniques that we can use to improve the performance? Also, I was wondering whether we can configure Drools to operate directly on the data in the database.

 

Thanks

Bhaskar