\svnInfo $Id$  

\noindent Distributed in-memory caching of application data has
recently become a popular solution for improving the scalability of
database-driven web sites. These systems provide a simple and flexible
interface, are easy to add to existing setups, and increase
performance significantly, reducing load not only on the database, but
on application servers as well. Unfortunately, such caches do not guarantee
transactional consistency, violating the isolation properties of the
underlying database.  Moreover, the application is responsible for
keeping data in the cache up-to-date, making programming difficult
because the developer must reason globally to identify every cached
value that an update might affect.

We introduce a transactional cache that provides transactional
consistency and a simple programming model, while retaining the
flexibility and efficiency of a simple distributed, in-memory
application data cache.  Our system, \emph{\txcache{}}, runs read-only
transactions on slightly stale database snapshots, thus improving its
hit rate and allowing it to ensure consistency of transactions that
combine data from the cache and the database without blocking or
requiring invalidations.  This requires maintaining a multi-versioned
cache and automatically tracking the range of times over which each
cached value is valid based on the query results that contribute to
the value.  Our
experiments found that adding \txcache increased the throughput of a
web application by 77\%, showing that consistency does not
have to come at the price of performance in an application data
cache.


%\edatnote{DRKP}{Add summary of results}

% Our system, \emph{\txcache{}} uses a multi-version cache to allow
% read-only transaction to run slightly in the past while ensuring
% that they still see a consistent view of the database.  This novel
% technique ...


% Distributed in-memory caching of application data has recently become
% a popular approach for improving the scalability of database-driven
% web sites. These systems, such as \memcached, provide a simple and
% flexible interface: they store application-provided key/value
% mappings, like a distributed hash table. The cache can be used to
% cache the results of both database queries and application
% computations, reducing load on both the database and application
% servers. Because cache performance scales near-linearly with the
% number of servers, this technique is used extensively by a number of
% large websites, who find it to be the most cost-effective approach to
% improving performance.

% Unfortunately, such caches do not guarantee transactional consistency
% of the results they return, making them unsuitable for use in
% applications with strict consistency requirements. Moreover, the
% application is responsible for invalidating the cache, making
% programming difficult because the developer must reason globally to
% identify every change that might affect a cached value.

% We provide an alternative in a transactional cache, \emph{\txcache{}},
% which retains the flexibility and scalability of simple application
% data caches while providing transactional consistency and a simpler
% programming model.  \txcache uses a novel technique to improve
% performance and avoid explicit invalidations: it allows read-only
% transactions to run slightly in the past, but ensures that they see a
% consistent view of the database. This is achieved using a versioned
% cache, in which entries are automatically tagged with the range of
% times at which they are valid.


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

% LocalWords:  invalidations versioned
