In modern computing, developers often need to find out when external information (such as configuration files, the current time zone or time of day, and so on) changes.
There are many ways to solve this problem, of which notifications are just one. The main ways are:
Notifications—the subject of this document. Notifications are a combination of shared memory and message passing.
Polling—pulling the needed information from another application or from a file on a regular basis. This technique is wasteful of CPU resources and is thus strongly discouraged for general use. However, when combined with shared memory, polling is useful in certain specialized environments.
Shared memory—providing a common repository for shared information that can be accessed through pointers in multiple processes. This technique is used as part of notification mechanisms. However, by itself, it is not a sufficient solution because of poor responsiveness. It is generally combined with either message passing or polling.
Message passing—a “push” method in which the sending application tells the receiving application that the information has changed. By itself, this is a good technique in terms of responsiveness, but it can be problematic in terms of robustness because when a message is lost, the receiving application cannot obtain the new value.
Although notification mechanisms differ greatly in the details of their implementation, they share a common design goal: allowing the recipient of the notification to monitor a piece of information in such a way that minimizes overhead while enabling designs that are robust even if a notification gets lost.
What Is a Notification?
What Is Coalescing?
What Types of Shared Store Can Be Used?
What Message-Passing Mechanisms Can Be Used?
How Should Notifications Be Named?
Last updated: 2007-05-15