SIGMOD 99 http://www-db.ics.uci.edu Efficient Concurrency Control in Multidimensional Access Methods Kaushik Chakrabarti Sharad Mehrotra University of Illinois at Urbana Champaign University of California at Irvine Presented at ACM SIGMOD Conference June 1, 1999
31
Embed
SIGMOD 99 Efficient Concurrency Control in Multidimensional Access Methods Kaushik Chakrabarti Sharad Mehrotra University of.
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
SIGMOD 99 http://www-db.ics.uci.edu
Efficient Concurrency Control in Multidimensional Access Methods
• DBMS should allow applications to:(1) define their own data types and operations(2) define multidimensional access methods (AMs) for those data types for efficient
query processing
• OR technology solves (1)
• Generalized Search Trees (GiSTs) addresses (2)
SIGMOD 99 http://www-db.ics.uci.edu
Introduction • For successful integration, we need to support concurrent accesses via
GiST
• Concurrency control problems:(1) Preserve consistency of data structure(2) Prevent phantom anomalies
• (1) has been addressed in Kornacker, Mohan and Hellerstein, SIGMOD97
• This paper addresses the problem of phantom protection in GiSTs
SIGMOD 99 http://www-db.ics.uci.edu
Phantom
• Definition:– T1 reads a set of items satisfying some <search-condition>
– T2 creates data items that satisfy T1’s <search-condition> and commits
– T1 repeats its scan with the same <search-condition>,
gets a different set of items
• Serializability No phantoms
SIGMOD 99 http://www-db.ics.uci.edu
Example
SIGMOD 99 http://www-db.ics.uci.edu
Solution
• Predicate locks: costly
• Granular locks: efficient
SIGMOD 99 http://www-db.ics.uci.edu
Key Range Locking
• ARIES/KVL(Mohan, 1990)
SIGMOD 99 http://www-db.ics.uci.edu
Phantoms in Spatial/Spatio-temporal Databases
• Compute average rainfall over all locations a 2-d region where the locations are indexed using a GiST
• Get all objects in a given region from a moving objects database where the objects are indexed using a GiST
SIGMOD 99 http://www-db.ics.uci.edu
Solutions
• Adapting KRL: too costly.
• Predicate locking based strategy by Kornacker, Mohan and Hellerstein, SIGMOD97.
• Our granular locking based approach for phantom protection in R-trees, ICDE98. Does not work well when applied to GiSTs (details in paper)
SIGMOD 99 http://www-db.ics.uci.edu
Granular Locking in GiST
• Solution involves– Define the granules– Define the lock protocol for the operations
• Challenges– “nice’’ granules– handling overlap among granules– handling “loss of lock’’ problem– high concurrency and low lock overhead
SIGMOD 99 http://www-db.ics.uci.edu
GiST
• Keys can be arbitrary predicates• An AM can be implemented by specifying some
extension methods which dictate the tree operations
SIGMOD 99 http://www-db.ics.uci.edu
Granules in GiST
• Leaf Granules: One per leaf node
• Non-leaf granules: One per non-leaf node
• Lock name: <table-name, index-name, node-id>
• Lock Coverage: defined by Granule Predicate (GP)
– GP(N) = BP(N) if N is root
= BP(N) GP(P) otherwise, P=parent(N)
SIGMOD 99 http://www-db.ics.uci.edu
SIGMOD 99 http://www-db.ics.uci.edu
Locks
SIGMOD 99 http://www-db.ics.uci.edu
Overlap between granules• Correctness: p p’ lset(p) lset(p’) NULL