[rules-users] Re: Is this scenario suitable for using Drools?

Cheng Wei Lee zhenwei.li at gmail.com
Tue Apr 22 12:27:28 EDT 2008


I've 2 algorithms to calculate the cost of a product. At any one time, there
is only 1 algorithm in use. Initially algorithm 1 will be the default.
Subsequently, the decision to use which algorithm will depend on customers
feedback. The algorithms are:

Algorithm 1:
Cost = MAX(P1, T1, P2, T2, P3, T3, ...)

Algorithm 2:
Cost = MIN(P1, P2, P3, ...) + MIN(T1, T2, T3, ...)

The values of P1, P2, ... are stored within a database. The number of Ps &
Ts are unknown but can be determined by querying the database, Would drools
be a good option to use to store the algorithms? If so, how could I be able
to retrieve the values of P1, P2, etc from the database from within drools?

Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20080423/7f2d6a87/attachment.html 


More information about the rules-users mailing list