1
我想为我们的项目之一 - Online Buying and Selling使用drools。使用Drools根据事件执行操作
事件就像买一本书,买笔,买一个kindle。 这些事件存储在数据库中。
现在,根据之前发生的事件,我想确定结果。
好比说,如果一个人具有以下序列,
1. Buy a book at a price.
2. Sell the same book at a higher price.
然后
Do something based on that.
如果有人这样做,
1. Buy a kindle.
2. Purchase a book in Science Section of books.
然后
show him the relevant content in the UI.
我在数据库中列出了所有事件。 现在我已经编写了要完成的操作界面,并且我还完成了事件发生时传递客户的界面。
现在,什么会给我最好的表现来处理事件,并根据事件的顺序做出决定。我无法将所有事件都存储在内存中,因为我有很多这些事件。