Forum OpenACS Q&A: Response to Building a marketplace: NYSE, NASDAQ, CBOT

Collapse
Posted by Andrew Piskorski on
Hm, "hard active" datbases, the Rete, TREAT, and LEAPS algorithms, the old HiPAC, VenusDB, and Sentinel projects. Interesting stuff, but yes, seemingly very little that's usefull to RDBMS users in the real world. Most of the research papers also seem to be old, not much in the last five years or so. It's not clear whether anyone's working on this stuff at all right now.

It would be nice to have this kind of Rete-algorithm capability in an RDBMS like Oracle or PostgreSQL. I don't know how triggers are implemented in Oracle exactly, but they definitely are not as sophisticated as rule-based systsms which use the Rete algorithm. I ran into this back when I was implementing an online bond trading site (which worked, but never even remotely approached the size of the NYSE!).

I forget the exact error, but Oracle does not allow recursive trigger execution. So, if you have programmed trades in the system, and you execute one order which changes system information (like "volume of this security traded today"), which could then cause another trade to execute - you have a problem. One can imagine ways to program around this limitation in Oracle, but a more general solution for such scenarios may call for something like the "coupling modes" introduced by HiPAC. At the time, our approach was simply to Not Do That; we avoided adding any features that would cause recursive trigger execution.