Transactional Support in Native Xml Databases

Transactional Support in Native Xml Databases

TRANSACTIONAL SUPPORT IN NATIVE XML DATABASES Theo Härder, Sebastian Bächle and Christian Mathis University of Kaiserslautern, Gottlieb-Daimler-Str., 67663 Kaiserslautern, Germany Keywords: XML database management, concurrency control, logging and recovery, elementless XML storage. Abstract: Apparently, everything that can be said about concurrency control and recovery is already said. None the less, the XML model poses new problems for the optimization of transaction processing. In this position paper, we report on our view concerning XML transaction optimization. We explore aspects of fine-grained transaction isolation using tailor-made lock protocols. Furthermore, we outline XML storage techniques where storage representation and logging can be minimized in specific application scenarios. 1 INTRODUCTION set of standards for information exchange and representation. It seems, the more domains are When talking about transaction management, every- conquered by XML (by defining schemas for body implicitly refers to relational technology. It is business cooperation), the more the relational true that the basic concepts of ACID transactions systems approach “legacy”. (Härder and Reuter, 1983) were primarily laid in the Hence, efficient and effective transaction-pro- context of flat table processing and the related query tected collaboration on XML documents (XQuery languages and later adjusted to object orientation. As Update Facility) becomes a pressing issue. a major advance for transaction processing, Weikum Solutions, optimal in the relational world, may fail and Vossen (2002) unified concurrency control and to be appropriate because of the documents’ tree recovery for both the page and object model. Perfor- characteristics and differing processing models. mance concerns led to a refinement of the page Structure variations and workload changes imply model to exploit records as more fine-grained units that transaction-related protocols must exhibit better of concurrency control. Their textbook used as the flexibility and runtime adjustment. “Blind” transfer “bible” in academic lectures “synthesizes the last of relational technology would lead to suboptimal three decades of research into a rigorous and solutions for storage and logging, because the consistent presentation” and it systematically structure part of XML often exhibits huge describes and “organizes that huge research corpus redundancies. into a consistent whole, with a step-by-step de- Because a number of language and processing velopment of ideas” (J. Gray in the foreword of this models are available and standardized for XML textbook). It seemed that everything that can be said (DOM, XQuery), general solutions for transaction about concurrency control and recovery is said in support have to consider protocols for concurrently this textbook already. evaluating stream-, navigation-, and path-based But new data models and processing paradigms queries. For this reason, a flexible XML database arrived in the recent past. The available types of management system (XDBMS) has to support data, their modeling flexibility, and their contents XPath, XQuery, and DOM/SAX. DB requests themselves have substantially evolved and more and specified by different XML languages may be more surpass the realms where the relational model scheduled and arbitrary transaction mixes may is appropriate. Above all, the importance of efficient occur. Therefore, serializability has to be guaranteed XML query processing in multi-user environments for those applications. grows along with the rapidly increasing sizes and In the following, we will outline that novel volumes, the advanced applications and the approaches for XML concurrency control, document pervasiveness of XML. For semi-structured data, storage, as well as logging and recovery may have XML together with its usages has become a (large) substantial saving and optimization potential. 368 Härder T., Bächle S. and Mathis C. (2008). TRANSACTIONAL SUPPORT IN NATIVE XML DATABASES. In Proceedings of the Tenth International Conference on Enterprise Information Systems - DISI, pages 368-373 DOI: 10.5220/0001725303680373 Copyright c SciTePress TRANSACTIONAL SUPPORT IN NATIVE XML DATABASES 2 LOCK PROTOCOLS - IRNRLRSRIXCXSUSX IR+++++++- - So far, there hardly exist any specific concurrency control protocols for XML. Only some hierarchical NR + + + + + + + - - lock protocols are available from the relational LR + + + + + + - - - world by adjusting the idea of multi-granularity SR+++++- - - - locking (Gray, 1978) to the specific needs of XML IX++++-++- - trees. Note, the well-known B-tree latch protocols (Graefe, 2007) cannot be used to isolate XML CX + + + - - + + - - transactions; they only isolate concurrent read/write SU+++++- - - - operations on B-trees and preserve their structural SX+-------- consistency. In contrast, locks isolate concurrent transactions on user data and – to guarantee Figure 1: taDOM2 lock compatibilities. serializability – have to be kept until transaction commit. With similar arguments, index locking can Using the IRIX protocol, a transaction reading not cope with the navigational DOM operations nodes at any tree level had to use R locks on the (Mohan, 1990). nodes accessed thereby locking these nodes together When fine-granular access to document trees has with their entire subtrees. This isolation is too strict, to be achieved, declarative requests have to be trans- because the lock protocol unnecessarily prevents lated into sequences of navigating operations. There- writers to access nodes somewhere in the subtrees. fore, the DOM model is considered, even for Giving a solution for this problem, we want to declarative languages, an adequate representative as sketch the idea of lock granularity adjustment to far as locking requirements are concerned. DOM-specific navigational operations. We repeat neither hierarchical lock protocols used in all industrial-strength DBMSs (Gray and 2.2 Fine-Grained DOM-Based Locking Reuter, 1993) nor our own work on XML locking (Haustein and Härder, 2008). Instead, we refer to To develop tailor-made XML lock protocols, Hau- these well-known protocols and only emphasize stein and Härder (2008) have introduced a far richer important properties for better comprehension. set of locking concepts and developed a family con- sisting of four DOM-based lock protocols called the 2.1 Multi-Granularity Locking taDOM group. While MGL essentially rests on intention locks and, in our terms, subtree locks, Hierarchical lock protocols – also denoted as multi- these protocols additionally contain locking concepts granularity locking (MGL) – are used “everywhere” for nodes and levels. in the relational world. For performance reasons in We differentiate read and write operations and XDBMSs, fine-granular isolation at the node level is rename the well-known (IR, R) and (IX, X) lock needed when accessing individual nodes or modes with (IR, SR) and (IX, SX) modes, traversing a path, whereas coarser granularity is respectively, to stress that subtrees (S) are locked. appropriate when traversing or scanning entire trees. As in the MGL scheme, the U mode (SU in our Therefore, lock protocols, which enable the isolation protocol) plays a special role, because it permits lock of multiple granules each with a single lock, are also conversion. Novel concepts are introduced by node beneficial in XDBMSs. Regarding the tree structure locks and level locks whose lock modes are NR of documents, objects can be isolated acquiring the (node read) and LR (level read) in a tree which, in usual subtree locks with modes R (read), X contrast to MGL, read-lock only a node or all nodes (exclusive), and U (update with conversion option), at a level, but not the corresponding subtrees. which implicitly lock all objects in the entire subtree Together with the CX mode (child exclusive), these addressed. To avoid lock conflicts when objects at locks enable serializable transaction schedules with different levels are locked, so-called intention locks read operations on inner tree nodes, while with modes IR (intention read) or IX (intention concurrent updates may occur in their subtrees. exclusive) have to be acquired along the path from While the remaining locks in Figure 1 coincide with the root to the object to be isolated and vice versa those of the URIX protocol, we highlighted these when the locks are released. Hence, we can map the three lock modes to illustrate that they provide a relational IRIX protocol to XML trees and use it as a kind of tailor-made XML-specific extension. generic solution. 369 ICEIS 2008 - International Conference on Enterprise Information Systems bib IR IX IX node – delivered for free by prefix-based node 1 2 3 labeling schemes (O’Neil et al., 2004) such as publication IR IX IX SPLIDs (stable path labeling identifiers) –, 1 2 3 identification of its children is very expensive, book LR IX LRQ: CX 1 2 3 because access to the document is needed to IX explicitly locate all affected nodes. By introducing . 2 titleauthor price suitable intention modes, Haustein and Härder CX (2008) obtained the more complex protocol The Title 2 49.99 fname lname NR taDOM2+ having 12 lock modes. The DOM3 1 First Name Last Name SX standard introduced a richer set of operations which 2 led to several new tailored lock modes for taDOM3 Figure 2: Application of the taDOM2 protocol. and – to optimize specific conversions – even more intention modes resulted in the truly complex Figure 1 contains the compatibility matrix for protocol

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    6 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us