The Database Alert Problem

Today's relational database products are passive and lack sophisticated features to let the database be aware of how changes to one row of data can affect another. They do support primitive tools that can be used for this purpose - triggers and referential integrity constraints.

Active vs. Passive Databases

Quotes from selected papers:

"In conventional (passive) database management systems data is created, modified, deleted and retrieved in response to requests issued by users or applications. In the mid-80s database technology was confronted with monitoring applications that required the reaction to changes in the database. To avoid wasteful polling, passive database functionality was extended with ECA rules to allow the database system itself to perform certain operations automatically in response to the occurrence of predefined events. Those systems are known as active DBMSs [1, 63, 53]. They are significantly more powerful than passive DBMSs since they can (efficiently) perform functions that in passive database systems must be encoded in applications. The same mechanism can also be used to perform tasks that require special-purpose subsystems in passive databases 172 Mariano Cilia et al. (e. g., integrity constraint enforcement, access control, view management, and statistics gathering). Historically, production rules were the first mechanism used to provide automatic reaction functionality. Production rules are Condition-Action rules that do not break out the triggering event explicitly. Instead, they implement a pollingstyle evaluation of all rule conditions. In contrast, ECA rules explicitly define triggering events, e. g., the fact that an update or an insert occurred, and conditions on the content of the database are only evaluated if the triggering event is signaled. ECA rules consist of three parts: a lightweight Event causes the rule to be fired; an (optional) Condition is checked when the rule is fired; and an Action is executed when the rule is fired and its guarding condition evaluates to true. In active relational databases, events were modelled as changes of state of the database, i. e., insert, delete and update operations that could trigger a reaction [31, 59]. This basic functionality is common fare in today’s commercial DBMSs in the form of triggers. In object-oriented systems, ECA rules are considered as first-class objects [17]. This treatment of ECA rules as first-class entities enables them to be handled homogeneously like any other object. In these systems more general events were defined: temporal, method invocation (with before and after modifiers), and user-defined events [17, 3, 28, 11, 66]. In addition to these events, more complex situations that correlate, aggregate or combine events can be defined. This is done by using an event algebra [28, 67] that allows the definition of composite or complex events."

The Convergence of AOP and Active Databases: Towards Reactive Middleware Mariano Cilia, Michael Haupt, Mira Mezini, and Alejandro Buchmann


"Passive database management systems (DBMSs) are program-driven - users query the current state of database and retrieve the information currently available in the database. Active DBMSs, on the other hand, are data-driven - users specify to the DBMS the information they need. If the information of interest is currently available, the DBMS immediately provides it to the relevant users; otherwise, the DBMS actively monitors the arrival of the desired information and provides it to the interested users as it becomes available. In other words, the scope of a query in a passive DBMS is limited to the past and present data, whereas the scope of a query in an active DBMS additionally includes future data. An active DBMS reverses the control flow between applications and the DBMS - instead of only applications calling the DBMS, the DBMS may also call applications in an active DBMS."

Ulf Schreier , Hamid Pirahesh , Rakesh Agrawal , C. Mohan, Alert: An Architecture for Transforming a Passive DBMS into an Active DBMS, Proceedings of the 17th International Conference on Very Large Data Bases, p.469-478, September 03-06, 1991


"In the past, databases were passive, low-level repositories of data on top of which smarter, domain-focused applications were built. Lately, databases have taken a more active role, offering more advanced services and higher functionality to other applications. In this framework, the database assumes responsibility for execution of some tasks previously left to the application, which offers several advantages: the possibility of better performance (since the database has direct access to the data, knows how the data is stored and distributed), better data quality (since the database is already in charge of basic data consistency) and better overall control. However, this trend has resulted in the database taking in more ambitious roles, and having to provide more advanced functionality than in the past. One of the areas where this trend is clear is in the area of active databases. In the past, the database could monitor data and respond to certain changes via triggers (also called rules1). However, commercial systems offer very limited capabilities in this sense. In addition to problems of performance (triggers add quite a bit of overhead) and control (because of the problems of non-terminating, non-confluent trigger sets), trigger systems are very low-level: while the events that may activate a triggers are basic database actions (insertions, deletions and updates), users are interested in complex conditions that may depend on several database objects and their interactions. It is difficult to express this high-level, application-dependent events in triggers."

Active database systems for monitoring and surveillance, Antonio Badia, Lecture notes in computer science ISSN 0302-9743

Active Databases

Active databases were investigated in the 1980's and 1990's at Xerox, IBM, and at universities.

This paper describes some of the difficulties researchers encountered:

Practical Applications of Triggers and Constraints: Successes and Lingering Issues

In the late 1990's, Active database research seemed to fall out of interest and was succeeded by research into:

-- ScottLangley - 23 Apr 2009