% $Id: relwork.tex,v 1.11 2004/05/16 18:28:51 gokhale Exp $

\section{Related Work}
\label{related}

This section surveys literature on Pu\-bli\-sher/Subs\-criber
systems, both standards based and proprietary, concentrating on
publisher/subscriber systems for real-time systems. None of the prior
work deals with component middleware with {\em real-time QoS support}, 
which is the focus of our work.

\subsection{Standards-based Publisher/Subscribers}
\label{sec:survey:standard}

\sqzpar\paragraph{$\bullet$ The CORBA Event Service}

The CORBA Event Service is a specification that defines a basic
Publisher/Subscriber architecture for CORBA systems.  In the CORBA
Event Service the Publishers are called \emph{Suppliers}.  Suppliers
can be either push-style or pull-style, the first pro-actively
generate events and send those events to the event channel for
distribution.  Pull-style suppliers passively wait until the event
channel requires an event and supply one if the event is available.
Likewise, the CORBA Event Service uses \emph{Consumers} to play the
Subscriber role.  Consumers can also be pull-style or push-style, the
first style requires consumers to periodically or pro-actively query
events from the event service.  Push-style consumers are simply
notified when a new event is available.  Both styles can be mixed, in
other words, push-style consumers can receive events generated by
pull-style suppliers, or vice-versa.  The CORBA Event Service does not
provide any mechanisms to control QoS behavior, and filtering is
limited to the so-called \emph{Typed Event Channels} where consumers 
and suppliers can receive a specific IDL-type.
However, Typed Events is an optional compliance point in the CORBA
Event Service and very few implementations for this variant of the
service exist.  Therefore, in practice, filtering is not supported.

There are several commercial CORBA-compliant Event Service
implementations available from multiple vendors, such as IONA and
Borland.  IONA also produces OrbixTalk, which is a messaging service
based on UDP/IP multicast.  Since the CORBA Event Service
specification does not address issues critical for real-time
applications, the QoS behavior of these implementations are not
acceptable solutions for many application domains.

\sqzpar\paragraph{$\bullet$ The CORBA Notification Service}

The OMG has issued a specification for a Notification
Service~\cite{CORBAService:99a}, which is a superset of the CORBA
Event Service.  This specification adds interfaces for event
filtering, configurable event delivery semantics (e.g., at least once
or at most once), security, and event delivery QoS. 

\sqzpar\paragraph{$\bullet$ The CORBA Distributed Notification Service}

The OMG has also issued a specification to build distributed versions
of the Notification Service via its ``Management of Event Domains
Specification''~\cite{CORBAService:01b}.
This document describes how multiple instances of the Notification
Service can be interconnected to avoid the excessive overhead and
eliminate the single point of failure represented by the Event Channel
object.
This specification, however, does not incorporate any mechanisms to
reduce event delivery based on filters.
Also, both the CORBA Notification Service and the CORBA Distributed 
Notification Service are based on Object-Oriented middleware rather than 
component middleware.
%\sqzpar\paragraph{COBEA}

\subsection{Proprietary Publisher/Subscriber Systems}
\label{sec:survey:proprietary}

\sqzpar\paragraph{$\bullet$ Cadena Event Channel Framework}

Cadena Event Communication Framework~\cite{Singh:04} includes a
CORBA-based event channel which has been integrated into the OpenCCM
infrastructure. The framework implements a number of features of the
event service middleware, such as event filtering, event correlation,
and direct-dispatching. Although this work comes close to our work,
however, it does not address the problems 
such as real-time event scheduling and dispatching and periodic event 
processing, which are crucial for a lot of mission-critical real-time
applications. Our work, on the other hand, leverages the RT event
channels and QoS-enabled component middleware to provide the
properties outlined above.  

\sqzpar\paragraph{$\bullet$ SIENA}

SIENA~\cite{Carzaniga:01,Carzaniga:00} is a notification service
architecture for Internet-scale event distribution.  The architecture
is based on \emph{content-based networking}, where a network of
routers propagate packets based not on a specific destination
address, but on the contents of the packet.
The authors propose using an event format similar to the CORBA
Notification Service, {\em i.e.}, sequence of $(name,value)$ tuples.
Using this format consumers use a boolean predicate on the tuple
values to describe the sets of events they are interested in.  The
authors describe algorithms to reduce the use of network
resources. For example, the authors propagate filtering information as
close to the sources as possible, likewise, filtering constraints are
combined and simplified to minimize the use of computation resources
in the routers.

Both SIENA and TAO's Real-time Event Service use similar techniques to
conserve network and CPU resources, however, SIENA's event and
filtering models are more powerful than the model in our Real-time
Event Service.  In contrast, however, our real-time Event Service is better
suited for applications with stringent latency and predictability
requirements, such as avionics mission computing.

\sqzpar\paragraph{$\bullet$ ECO}

The Distributed Systems Group at Trinity College, Dublin has developed
ECO~\cite{Starovic:95}, for ``Events, Constraints and Objects.''
The authors propose building programs out of cooperating objects that
publish or subscribe to events as needed.  Filtering, concurrency and
timeliness constraints are expressed as constraints on the events that
a particular object publishes or subscribes to.

The authors propose extending
general-purpose programming languages, such as C++ or Java, to include
explicit declarations for events, as well as the types of events that
a class can subscribe or publish.  Naturally, this static publications
or subscriptions can be further restricted at run-time, the authors
propose using new language statements for this purpose.

Objects can add \emph{Notify} constraints to limit the objects that
they subscribe to, this conditions are evaluated at the source of the
event and thus are limited to constraints on the event parameters or
the source identity.  Objects can also define \emph{Pre} and
\emph{Post} constraints, this are evaluated on the destination object
and can use the state of the receiving object to affect the event
processing.  \emph{Pre} constraints are evaluated before the event is
delivered and can determine if the event is dropped, enqueued or
processed immediately.

\sqzpar\paragraph{$\bullet$ CMU Real-time Publisher/Subscriber}

Rajkumar, \emph{et al.}, describe a real-time
pub\-lish\-er/sub\-scrib\-er prototype developed at CMU SEI
\cite{Rajkumar:95}.  Their Pub\-lish\-er/Sub\-scrib\-er model is
functionally similar to the CORBA Event Service, though it defines its
own programming APIs and communication protocols.
The authors details how real-time threads and adequate synchronization
primitives can be used to implement the RT P/S model without undue
priority inversions.
However, the authors also fail to recognize that adequate
synchronization primitives are a necessary condition to address
unbounded priority inversions, but it is not a sufficient condition.
For example, the authors do not detail how their algorithms avoid
critical sections with time bounds dependent on the number of
participants in the system.

\subsection{Summary}

Much has been written about Publisher/Subscriber systems, but there is
little effort has been documented on the patterns, optimizations 
and architectures required to implement QoS-aware Publisher/Subscriber models
in component-based software architectures. Also, there is very little or 
no empirical evidence to support the performance and predictability
claims of several  of these systems, even when research concentrates
on real-time applications.

\iffalse
There is also very little or no research on how to implement real-time
or high-scale Publisher/Subscriber systems for standards-based
middleware.  Likewise, there is very little or no empirical evidence
to support the performance and predictability claims of several of
these systems, even when research concentrates on real-time
applications.  In many cases, the empirical results are insufficient
to evaluate if the predictability, performance or scalability goals
can be achiever.  For example, many papers simply present average
performance results, without describing the jitter, observed
worst-case or observed data distributions.
\fi



