\svnInfo $Id$  

In order to present an easy-to-use interface to application
developers, \txcache needs to store cached data, keep it up to
date, and ensure that data seen by an application is transactionally
consistent. This section and the following ones describe how it
achieves this using cache servers, modifications to the database, and
an application-side library. None of this complexity, however, is
visible to the application, which sees only cachable functions.

An application running with \txcache accesses information from the
cache whenever possible, and from the database on a cache miss. To
ensure it sees a consistent view, \txcache uses versioning. Each
database query has an associated \emph{validity interval}, describing
the range of time over which its result was valid, which is computed
automatically by the database. The \txcache library tracks the queries
that a cached value depends on, and uses them to tag the cache entry
with a validity interval. Then, the library provides consistency by
ensuring that, within each read-only transaction, it only retrieves
values from the cache and database that were valid at the same
time. Thus, each transaction effectively sees a snapshot of the
database taken at a particular time, even as it accesses data from the
cache.

Section~\ref{sec:cache} describes how the cache is structured, and
defines how a cached object's validity interval and database
dependencies are represented. Section~\ref{sec:database} describes how
the database is modified to track query validity intervals and provide
invalidation notifications when a query's result
changes. Section~\ref{sec:library} describes how the library tracks
dependencies for application objects, and selects consistent values
from the cache and database.

%%% Local Variables: 
%%% mode: latex
%%% TeX-PDF-mode: t
%%% TeX-master: "paper.tex"
%%% End: 

% LocalWords:  transactionally versioning
