<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>UUssiinngg ttaaDDOOMM LLoocckkiinngg PPrroottooccooll iinn aa FFuunnccttiioonnaall XXMMLL UUppddaattee LLaanngguuaaggee</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Pavel Strnad</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Pavel Loupal Pavel Strnad</string-name>
          <email>loupalp@fel.cvut.cz</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Pavel Loupal</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Department of Computer Science and Engineering FacultDyeopfarEtlmecetnrticoafl CEonmgipnueetreirnSg,ciCenzceechanTdecEhnigcianleeUrninivgersity Faculty of ElKecatrrliocvaol En ́anmgiˇensete ́ır1in3g,,1C21ze3c5h PTreachani2cal University Karlovo n ́amˇest ́ı 13C</institution>
          ,
          <addr-line>z1e2c1h 3R5epPurabhliac 2</addr-line>
          ,
          <country country="CZ">Czech Republic</country>
        </aff>
      </contrib-group>
      <fpage>25</fpage>
      <lpage>36</lpage>
      <abstract>
        <p>In this paper we deal with a particular type of database systems - native XML database systems. For this category of systems we discuss potential application of the taDOM locking protocol implemented in a functional update language - XML-λ. By combination of these theoretical approaches we obtain a solution for querying and updating XML data that can be implemented in a native XML database system with transaction support. We present an LL(1) translation grammar for transformation of queries written in a functional language into sequence of Document Object Model API calls.</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>Motivation</title>
      <p>Currently, our research group works on development of a native XML database
system that uses XQuery and should also use the XML-λ query language.
Therefore we are interested in properties and interconnections between these two
artifacts. XQuery represents de-facto industrial standard in querying and XML-λ
is a proposal of our group based on simply typed λ-calculus.</p>
      <p>
        In this paper we submit a proposal for transformation of XML-λ statements
into a list of DOM operations with ensured transaction isolation through the
DOM-based locking protocol – taDOM. We plan to use this solution for
extending our native XML database system in the future.
The crucial property of modern database management systems (DBMS) [
        <xref ref-type="bibr" rid="ref11">11</xref>
        ] is
concurrent user access. In this work we discuss it in context of a specific type of
database systems – native XML database systems. Such systems are primarily
used for storing XML data in their original form instead of mapping its structures
into e.g. objects or relations.
      </p>
      <p>
        We outline an existing locking protocol that was developed for XML data –
taDOM [
        <xref ref-type="bibr" rid="ref14">14</xref>
        ] – and use it for a particular functional query and update language –
XML-λ [
        <xref ref-type="bibr" rid="ref19 ref20">19, 20</xref>
        ]. It is a proposal of a functional framework for querying and
manipulating XML data. It is established on type system theory and utilizes
simply typed λ-calculus as a base for specification of a query language. This
project is currently in phase of development and in future we plan to include
an XML-λ module into native XML database systems we currently work on –
CellStore [
        <xref ref-type="bibr" rid="ref25">25</xref>
        ] and ExDB [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ].
      </p>
      <p>
        The approach we present in this paper is as follows: we transform basic update
operations into standard DOM [
        <xref ref-type="bibr" rid="ref24">24</xref>
        ] operations that are supported by taDOM
and so we can introduce transactional behavior into the language. Formally, we
use an LL(1) translation grammar for converting XML-λ expressions to DOM
API method calls.
      </p>
      <p>
        The main contribution of this paper lies in combining the taDOM locking
protocol and XML-λ query/update language. We offer a proposal how to interface
referenced locking protocol and low-level update operations in given language
using DOM operations. This work continues in the topic that we have opened
in [
        <xref ref-type="bibr" rid="ref17">17</xref>
        ]. In this text we clarify more the update facility of the framework and
design a translation grammar that provides the solution for transformation of
XML-λ update statements into DOM operations.
      </p>
      <p>The rest of the paper is structured as follows: Section 3 gives a short overview
about concurrency and related issues in database systems, Section 4 then outlines
the idea of the taDOM locking protocols family. Basic concept of XML-λ with
its key update features is briefly introduced in Section 5. The main part of
this work that describes our proposal for mapping of DOM operations to the
query language is presented in Section 6. In Section 7 we gather a list of certain
related papers available. Finally, we conclude with ideas for our future research
in Section 8.
3</p>
    </sec>
    <sec id="sec-2">
      <title>Concurrency in Native XML DBMS</title>
      <p>
        Common requirement for a database management system is the concurrency
control. There are four well-known properties for a transactional system known
as ACID [
        <xref ref-type="bibr" rid="ref11">11</xref>
        ]. Transaction is generally a unit of work in a database. ACID
properties are independent on a database (logical) model (i.e. it must be kept in
all transactional database systems).
      </p>
      <p>
        Isolation of transactions in a database system is usually ensured by a locking
protocol. Direct application of a locking protocol used in relational databases
does not provide high concurrency [
        <xref ref-type="bibr" rid="ref15 ref22">15, 22</xref>
        ] (i.e. transactions are waiting longer
than it is necessary).
      </p>
      <p>
        We show a huge difference between locking protocols for RDBMS and native
XML database system on a small example. Let us have two lock modes: Shared
mode and Exclusive mode. The granularity of exclusive lock in RDBMS is
typically the row (or record) [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ]. In a native XML database we have much more
possibilities whether to lock a node or a whole subtree. Hence, we have more
choices what to lock and for how long time. These protocols working on XML
data extend the basic locking protocol. The basic protocol provides only two
types of lock modes, but taDOM3+ has twenty lock modes. More lock modes
imply more complexity in a protocol algorithm. Also to prove whether the
protocol is correct is a harder problem.
      </p>
      <p>
        We suppose only well-formed transactions and serializable plan of update
operations [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ]. All protocols quoted in this paper satisfy these requirements. We
call locking protocols for native XML databases simply XML-locking protocols
in this paper. The most of these XML-locking protocols are based on the basic
relational locking protocols. Hence, XML-locking protocols inherit most of the
features, e.g. two-phase locking to ensure serializability.
      </p>
      <p>
        To design a good locking protocol which minimizes the number of suspended
transactions is a challenge because it is much more complex than in RDBMS.
It requires new lock modes for individual elements and also for the axes in an
XML document [
        <xref ref-type="bibr" rid="ref22">22</xref>
        ]. The locking mechanism depends on the query language
used, concretely on the atomic operations of the query language and also on the
context of these operations.
4
      </p>
    </sec>
    <sec id="sec-3">
      <title>Locking Protocols</title>
      <p>
        Actual research in the area of locking protocols is concentrated rather to DOM
model and its methods of approaching individual parts of an XML document.
Probably the most advanced research in this topic is carried out at the University
of Kaiserslautern in Germany [
        <xref ref-type="bibr" rid="ref14 ref15 ref16">16, 14, 15</xref>
        ]. The researchers are working on XTC
(XML Transaction Coordinator) Project [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] – a system which implements several
different algorithms of transactional processing on XML data.
      </p>
      <p>XTC project uses extended DOM model (it is called taDOM) as a basis for
transactional processing.
4.1</p>
      <p>
        taDOM Family of Locking Protocols
The first version of the protocol was denominated as taDOM2. Its improved
version is then called taDOM2+. Both of these protocols work with DOM Level 2
operations (about 20 methods, see [
        <xref ref-type="bibr" rid="ref23">23</xref>
        ]). Next generation of taDOM locking
protocols are taDOM3 and taDOM3+. As expected, these protocols correspond
to DOM Level 3 model. The XTC project also provides detailed use cases for
these protocols (36 use cases) which completely describe locking scenarios for
each operation.
      </p>
      <p>Each of taDOM locking protocols is specified by:
– Compatibility matrix
– Conversion matrix
– Use cases for DOM operations</p>
      <p>The compatibility matrix is used when the transaction t1 is requesting for
lock l1 on a node n and there is a lock l2 of the transaction t2. The locking
algorithm finds the row l1 and column l2 in the compatibility matrix and makes
a decision whether to lock (+) or not (-). Table 1 describes Compatibility Matrix
for edge locks (ER - edge read, EU - edge update and EX - edge exclusive).</p>
      <p>- ER EU EX
ER + + -
EU + + -</p>
      <p>EX + - -</p>
      <p>The conversion matrix is used when the transaction t1 is requesting for lock l1
on a node n and there is a lock l2 of the same transaction t1. Locking algorithm
finds the row l1 and column l2 in the conversion matrix and converts the lock
mode of the node. Hence, each transaction has at the most one lock on each
node.</p>
      <p>Use cases describe semantics of the locking protocol with regard to DOM
operations. Table 2 contains description of the DOM operation getN ode(nodeID).
When getN ode(nodeID) operation is called then the locking mechanism has
to put the lock of type NodeRead (NR) on the context node(CN). PSE, NSE,
FCE, LCE are abbreviations for previous sibling edge, next sibling edge, first
child edge, last child edge. The getN ode(nodeID) operation does not put locks
on these virtual edges (-).</p>
      <p>
        We consider only taDOM3+ in the next sections of this paper. This
protocol is up-to-date nowadays, because it reflects today’s needs and was formally
checked1. The taDOM3+ locking protocol has also really low overhead
(minimizes access to the storage) [
        <xref ref-type="bibr" rid="ref14">14</xref>
        ].
      </p>
      <p>
        taDOM3+ protocol provides level 2.99 of isolation [
        <xref ref-type="bibr" rid="ref15 ref4">4, 15</xref>
        ]. It means that
phantom reads2 are not covered. Therefore it is necessary to do a small extension to
these protocols by adding navigation edges to avoid existence of phantom reads.
We need to define an additional mechanism – edge locks. To apply edge locks the
authors had to extend the XML document model and added new edges between
nodes – virtual edges. The compatibility matrix of these locks is discussed in
more details in [
        <xref ref-type="bibr" rid="ref15">15</xref>
        ].
taDOM Model Structure The tree-like structure in taDOM is enriched by
two new node types: attributeRoot and string [
        <xref ref-type="bibr" rid="ref14">14</xref>
        ]. This representational
en1 Valenta and Siirtola [
        <xref ref-type="bibr" rid="ref21">21</xref>
        ] made a formal proof of the protocol correctness. They
verified the taDOM locking protocol using model-checking.
2 Phantom read happens when new rows added by a transaction are visible from
another transaction
hancement does not influence user operations and their semantics on the XML
document, but is solely exploited by the lock manager to achieve certain kinds of
optimization when an XML document is modified in a cooperative fashion [
        <xref ref-type="bibr" rid="ref15">15</xref>
        ].
– attributeRoot separates various attribute nodes from their element node.
Instead of locking all attribute nodes separately they are locked all together
by placing the lock to attributeRoot – concurrency of attribute processing
is not allowed.
– A string node is attached to the respective text node and only contains the
value of this node. It does not allow to block a transaction which only
navigates across the node, although a concurrent transaction may have modified
the text (content) and may still hold an exclusive lock on it.
      </p>
      <p>Lock Modes The taDOM3+ protocol provides a set of lock modes for the
nodes as well as for the edges. Edge locks are used to cover phantom reads in an
XML document in order to allow desired level of concurrency. The lock modes
together with their mutual relationships (expressed as compatibility matrices)
provide concurrency and also preserve the expected ACID properties (especially
the level of isolation).
5</p>
    </sec>
    <sec id="sec-4">
      <title>Updating XML</title>
      <p>
        There are various theoretical proposals, experimental implementations and
defacto standards for XML update languages. As of the publication of the XML 1.0
standard [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ] the efforts had been focused on querying such structured data.
Approaches for updating have gained more attention in past few years.
      </p>
      <p>
        Existing papers dealing with updating XML are mostly related to XQuery [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ].
The need for introducing updates into XQuery is also considered as one of the
most important topics in the further development of the language [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ]. As a
result, new specification of the XQuery Update Facility [
        <xref ref-type="bibr" rid="ref9">9</xref>
        ] was proposed.
      </p>
      <p>
        In this paper we deal with our approach for querying and updating XML
data – XML-λ [
        <xref ref-type="bibr" rid="ref19 ref20">19, 20</xref>
        ]. It is a framework for manipulating XML based on a type
system and simply typed λ-calculus. It is a cornerstone of our long-term research
that was invented not only for definition of an update language for XML but
also for a broader exploitation, for example heterogeneous data integration or
description of denotational and operational semantics of various languages.
Indeed, in this paper we focus on using it as a query and update language for XML.
      </p>
      <p>In following paragraphs we expect that reader is familiar with basic
concept of the XML-λ Framework. Nevertheless, we repeat its basic concept for
convenience.
5.1</p>
      <sec id="sec-4-1">
        <title>Updates in General</title>
        <p>Query execution has in general the following structure: (1) Declaration of
variables, (2) Evaluation of variables and tree traversal and (3) Output construction.
For read-only systems and even parallel user access it is perfectly sufficient but
for systems with update support it is necessary to use a different approach.</p>
        <p>Usually, for particular update operations (in the world of native XML database
systems) a structure called ”pending update list” is utilized. This structure
contains ordered list of fundamental modification operations to be carried out at
the end of each transaction. Hence, the execution of an update operation (insert,
delete, replace) then follows these two steps: (1) node locking and (2) appending
an appropriate update operation to the list.</p>
        <p>At the end of each transaction the pending update list is processed and all
nodes locked by the transaction are unlocked at its end (both in case of commit
or abort). This approach is applied both in XQuery and XML-λ3. In following
sections we cover our solution based on XML-λ in detail.
5.2</p>
        <sec id="sec-4-1-1">
          <title>XML-λ Framework Basics</title>
          <p>
            XML-λ is a functional framework for manipulating XML. The original
proposal [
            <xref ref-type="bibr" rid="ref19 ref20">19, 20</xref>
            ] defines its formal base and shows its usage primarily as a query
language for XML but there is a consecutive work that introduces updates into
the language available in [
            <xref ref-type="bibr" rid="ref17">17</xref>
            ].
          </p>
          <p>In XML-λ there are three important components related to its type system:
element types, element objects and elements. We can imagine these components
as the data dictionary in relational database systems. Note also Figure 1 for
relationships between basic terms of W3C standards and the XML-λ Framework.</p>
          <p>Element types are derived from a particular DTD and in our scenario they
cannot be changed – we do not allow any schema changes but only data
modifications. For each element defined in the DTD there exists exactly one element
type in the set of all available element types (called TE).</p>
          <p>Consequently, we denote E as a set of abstract elements. Set members are of
element types.</p>
          <p>Element objects are basically functions of type either E → String or E →
(E × . . . × E). Application of these functions to an abstract element allows access
to element’s content. Elements are, informally, values of element objects, i.e. of
functions. For each t ∈ TE there exists a corresponding t-object.</p>
          <p>For convenience, we add a ”nullary function” (also known as 0-ary function)
into our model. This function returns a set of all abstract elements of a given
element type from an XML document.</p>
          <p>Finally, we can say that in XML-λ the instance of an XML document is
represented by a set E and set of respective t-objects.</p>
          <p>Example. Let us consider an example DTD and a fragment of an XML
instance shown in Figure 2. For given schema we derive element types as
follows: BIB : BOOK∗, BOOK : (T IT LE, AU T HOR+, P RICE), AU T HOR :
(LAST, F IRST ), LAST : String, F IRST : String, T IT LE : String, P RICE :
3 Note that both XQuery and XML-λ are functional languages.
String.</p>
          <p>Then, we define functional types – designated as t-objects: BIB : E → 2E,
BOOK : E → (E × 2E × E), AU T HOR : E → (E × E), T IT LE : E → String,
LAST : E → String, F IRST : E → String, P RICE : E → String.
&lt;!ELEMENT bib (book* )&gt;
&lt;!ELEMENT book (title, author+,</p>
          <p>price )&gt;
&lt;!ELEMENT author (last, first )&gt;
&lt;!ELEMENT title (#PCDATA )&gt;
&lt;!ELEMENT last (#PCDATA )&gt;
&lt;!ELEMENT first (#PCDATA )&gt;
&lt;!ELEMENT price (#PCDATA )&gt;
| &lt;bib&gt;
| &lt;book&gt;
| &lt;title&gt;TCP/IP Illustrated&lt;/title&gt;
| &lt;author&gt;
| &lt;last&gt;Stevens&lt;/last&gt;
| &lt;first&gt;W.&lt;/first&gt;
| &lt;/author&gt;
| &lt;price&gt;65.95&lt;/price&gt;
| &lt;/book&gt;
| ...</p>
          <p>Having look at the Figure 2 we can see that there are 7 abstract elements
(members of E0 ⊂ E). Now, for instance, the price-object is defined exactly for
one abstract element (the one obtained from &lt;price&gt;65.95&lt;/price&gt; element)
and for this abstract element it returns value ”65.95”.</p>
          <p>Let us consider a query that returns all books with price higher than 100.
This query is written in XML-λ as:
xmldata("bib.xml")
lambda b ( /book(b) and b/price &gt; 100))</p>
          <p>
            Here, we do not depict the query evaluation process in detail but it is
described sufficiently in [
            <xref ref-type="bibr" rid="ref19 ref20">19, 20</xref>
            ].
5.3
          </p>
        </sec>
      </sec>
      <sec id="sec-4-2">
        <title>Fundamentals of Updates</title>
        <p>By introspecting the basics of the framework outlined in Section 5.2 – especially
the idea of element objects we can see that by updating an XML document we
modify actual domains of element objects (i.e. partial functions defined on E)
and their ranges.
6</p>
      </sec>
    </sec>
    <sec id="sec-5">
      <title>Locking Protocol Mappings</title>
      <p>This section describes our solution for translation of XML-λ statements into
DOM API calls through a top-down parser directed by an attributed LL(1)
translation grammar.</p>
      <p>For easier specification of transformation between XML-λ primitives and
DOM operations we define new operation :
f +(v) = {f 1(v), f 2(v), f 3(v), . . .}</p>
      <p>∞
f +(v) g() = [ {g(f u(v))}</p>
      <p>u=1</p>
      <p>This operation is defined on sets. We can say that the g() function is applied
on each element of a set.
6.1</p>
      <sec id="sec-5-1">
        <title>A Pinch of Translation Theory</title>
        <p>
          We solve the problem of mapping by translation from one language to another.
The straightforward approach is based on construction of an attributed
translation grammar [
          <xref ref-type="bibr" rid="ref5">5</xref>
          ]. Then all queries written in XML-λ can be translated into a
sequence of DOM operations.
        </p>
        <p>Here we refer shortly to definition related to translation grammars – note
that we use an attributed translation grammar, i.e. a context-free grammar
augmented with attributes, output symbols and semantic rules.</p>
        <p>The attributed translation grammar is 4-tuple AP G =&lt; P G, A, V, F &gt;,
where PG is a basic translation grammar P G =&lt; N, Σ, D, R, S &gt;. N is set of
non-terminal symbols, Σ is set of terminals, D is set of output symbols, R is a
set of grammar rules A =&gt; α, where A ∈ N , α ∈ (N ∪ Σ ∪ D)∗ and S is the
start symbol.</p>
        <p>Remaining symbols are related to APG and have the following meaning
A is a finite set of attributes. It is divided into two disjoint sets for
synthesized (denoted S) and inherited (denoted I) attributes.</p>
        <p>V is a mapping that assigns a set of attributes to each non-terminal symbol X ∈ N
F is a finite set of semantic rules</p>
        <p>The example stated in the following section is based on this formalism.</p>
        <sec id="sec-5-1-1">
          <title>XML-λ to DOM Translation Grammar</title>
          <p>We use the standard formal translation directed by an LL(1) parser where the
formal translation is described by translation grammar as follows:
N = {S, R0, R1, T }
Σ = {/, sL, var}
D = { s , t , c }
R = { S → / R0|varR1,</p>
          <p>R0 → sL s T R1,
R1 → / c sL T R1| ,</p>
          <p>T → t }
Note that terminal symbols are output tokens from a lexical analyzer.
We proposed necessary attributes for translation A = {name, string}, where
I(T ) = {name}, I( t ) = {name}, S(sL) = {string}. Attributes are used for
storing tag names in the process of translation.</p>
          <p>Syntax and semantics of the translation grammar is described in Table 3.</p>
          <p>Syntax
S → / R0|varR1
R0 → sL s T R1
R1 → / c sL T R1|
T → t</p>
          <p>Semantics
T.name := sL.string
T.name := sL.string
t .name := T.name
After translation the output symbols are rewritten in following way:
s → doc getDocumentElement()
t → getT agN ame( t .name)
c → getChildN odes()
getChildN odes()+</p>
          <p>Following example shows how we can transform XML-λ queries to DOM
operations. These operations implicitly use taDOM3+ locking protocol
synchronization primitives.
6.3</p>
        </sec>
        <sec id="sec-5-1-2">
          <title>XML-λ Query Evaluation Example</title>
          <p>Let us have a look at an example of a delete operation in the XML-λ language.
Following statement deletes all books specified by given title:
xmldata("bib.xml")
delete( lambda b ( /book(b) and</p>
          <p>b/title = "TCP/IP Unleashed"))
We translate the inner expression of the statement
(/book(b) and b/title = "TCP/IP Unleashed")</p>
          <p>The translation is based on a top-down method using expansion operation ⇒.
Expansion rule depends on the top terminal of the processed input string. Then
we can use a standard LL(1) parser. Translation then starts as follows:
S ⇒ / R0 ⇒ / sL s T R1 ⇒ / sL s t R1 ⇒R1 / sL s t</p>
          <p>R0 T
By this derivation we have translated the first part of the expression – /book(b).
Then, we continue with the second part:
S ⇒ var R1 ⇒R1 var/ c sLT R1 ⇒ var/ c sL t R1 R⇒1 var/ c sL t</p>
          <p>T</p>
          <p>We get the translated string by omitting input symbols. We suppose that
the semantic rules were applied during translation. In the input symbol var we
saved the first part of the translation. The second part is concatenated with the
first part through the variable b. The output of the translation is the following
sequence of output symbols: s t c t .</p>
          <p>We can rewrite these output symbols to taDOM operations and then we get:
doc getDocumentElement() getChildN odes()+
getChildN odes() getT agN ame( t .name)
getT agN ame( t .name)</p>
          <p>The main part of the update statement is the path expression. Now we have
to select nodes which satisfy condition – title = ”T CP/IP U nleashed”. The
string comparison operation is not a DOM operation, so for purpose of this paper
is omitted here.</p>
          <p>The translation grammar described above can be directly used to ensure
isolation of transactions in the XML-λ language.
7</p>
        </sec>
      </sec>
    </sec>
    <sec id="sec-6">
      <title>Related Work</title>
      <p>
        First, considering query and update languages, there are many papers and
proposals. The most important specifications in the context of this work are the
XML Query Language 1.0 Specification [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ] and a Working Draft of the XQuery
Update Facility [
        <xref ref-type="bibr" rid="ref9">9</xref>
        ]. They form de-facto standard in the world of XML.
      </p>
      <p>
        Another branch of papers is focused on a specific database system and
describes usually a complete solution seen from a wider perspective. It is quite
a common practice that database groups at technical universities and similar
institutes develop their own database systems. In the area of XML we can
mention eXist [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ] or Natix [
        <xref ref-type="bibr" rid="ref12">12</xref>
        ]. Finally, we should also mention CellStore [
        <xref ref-type="bibr" rid="ref25">25</xref>
        ] – a
database system being developed at our department. Authors of these systems
usually describe in detail the transformation of XQuery statements into their
algebras.
      </p>
      <p>
        Issues related to transactions and systems that support transactional
behavior are covered as description of transaction protocols [
        <xref ref-type="bibr" rid="ref13 ref14 ref6">6, 13, 14</xref>
        ] or transactional
benchmarking [
        <xref ref-type="bibr" rid="ref18">18</xref>
        ].
8
      </p>
    </sec>
    <sec id="sec-7">
      <title>Conclusions and Future Work</title>
      <p>We have shown an approach for introducing fundamental transactional
operations into a functional query and update language for XML. Through the use
of the taDOM protocol and the XML-λ Framework we have obtained a
theoretical solution for native XML database systems that allows querying and
updating XML data in a safe manner. We accomplish this by introducing an
LL(1) attributed translation grammar for transformation of XML-λ statements
into sequence of DOM API calls. This forms a solid base for our ongoing
research – studying of mutual semantic transformations of queries written in one
query language into another, e.g. conversion of XQuery queries into XML-λ and
vice-versa.</p>
      <p>Considering the fact that we have presented here only first sketch of the
solution there is still a lot of clarification and experimental work ahead. In the
near future we plan to design and implement a prototype of the XML-λ query
engine into the CellStore database system. After that there are many open topics
related to correctness and benchmarking of the prototype.
9</p>
    </sec>
    <sec id="sec-8">
      <title>Acknowledgments</title>
      <p>We would like to thank to Jiˇr´ı Velebil for his valuable hints related to
mathematical expressions we use in this paper to formulate formalisms in a (hopefully)
clear way.</p>
      <p>This work has been supported by the Ministry of Education, Youth, and
Sports under Research Program MSM 6840770014.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1.
          <string-name>
            <given-names>ExDB</given-names>
            <surname>Project</surname>
          </string-name>
          <article-title>Homepage</article-title>
          . http://swing.felk.cvut.cz/~loupalp.
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>2. eXist Project Homepage. http://www.exist-db.org.</mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <given-names>XTC</given-names>
            <surname>Project</surname>
          </string-name>
          . http://wwwdvs.informatik.uni-kl.de/agdbis/projects/xtc.
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <given-names>A.</given-names>
            <surname>Adya</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Liskov</surname>
          </string-name>
          , and
          <string-name>
            <surname>P. O'Neil.</surname>
          </string-name>
          <article-title>Generalized isolation level definitions</article-title>
          .
          <source>ICDE</source>
          ,
          <volume>00</volume>
          :
          <fpage>67</fpage>
          ,
          <year>2000</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <given-names>A. V.</given-names>
            <surname>Aho</surname>
          </string-name>
          and
          <string-name>
            <given-names>J. D.</given-names>
            <surname>Ullman</surname>
          </string-name>
          .
          <source>The Theory of Parsing</source>
          , Translation, and
          <string-name>
            <surname>Compiling</surname>
          </string-name>
          . II. Compiling, volume II. Prentice-Hall, Upper Saddle River, NJ 07458, USA,
          <year>1973</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <string-name>
            <given-names>P.</given-names>
            <surname>Bernstein</surname>
          </string-name>
          and
          <string-name>
            <given-names>E.</given-names>
            <surname>Newcomer</surname>
          </string-name>
          . Principles of Transaction Processing. Morgan Kaufmann Publishers,
          <source>1st edition</source>
          ,
          <year>1997</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7.
          <string-name>
            <given-names>S.</given-names>
            <surname>Boag</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Chamberlin</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M. F.</given-names>
            <surname>Fern</surname>
          </string-name>
          ´andez,
          <string-name>
            <given-names>D.</given-names>
            <surname>Florescu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Robie</surname>
          </string-name>
          , and J.
          <source>Sim´eon. XQuery 1</source>
          .0:
          <string-name>
            <surname>An</surname>
            <given-names>XML</given-names>
          </string-name>
          <string-name>
            <surname>Query Language</surname>
          </string-name>
          ,
          <year>January 2007</year>
          . http://www.w3.org/TR/xquery/.
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8.
          <string-name>
            <given-names>T.</given-names>
            <surname>Bray</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Paoli</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C. M.</given-names>
            <surname>Sperberg-McQueen</surname>
          </string-name>
          ,
          <string-name>
            <given-names>E.</given-names>
            <surname>Maler</surname>
          </string-name>
          , and
          <string-name>
            <given-names>F.</given-names>
            <surname>Yergeau</surname>
          </string-name>
          .
          <article-title>Extensible markup language (XML) 1.0 (third edition</article-title>
          ),
          <year>February 2004</year>
          . http://www.w3.org/TR/2004/REC-xml-
          <volume>20040204</volume>
          /.
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          9.
          <string-name>
            <given-names>D.</given-names>
            <surname>Chamberlin</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Florescu</surname>
          </string-name>
          , and
          <string-name>
            <surname>J. Robie.</surname>
          </string-name>
          <article-title>XQuery update facility</article-title>
          . http://www.w3.org/TR/2006/WD-xqupdate-
          <volume>20060711</volume>
          /.
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          10. D. D. Chamberlin. XQuery:
          <article-title>Where do we go from here</article-title>
          ? In XIME-P,
          <year>2006</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          11.
          <string-name>
            <surname>C. J. Date</surname>
          </string-name>
          .
          <article-title>An Introduction to Database Systems, 6th Edition</article-title>
          . Addison-Wesley,
          <year>1995</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          12.
          <string-name>
            <given-names>T.</given-names>
            <surname>Fiebig</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Helmer</surname>
          </string-name>
          ,
          <string-name>
            <surname>C.-C. Kanne</surname>
            , G. Moerkotte,
            <given-names>J.</given-names>
          </string-name>
          <string-name>
            <surname>Neumann</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          <string-name>
            <surname>Schiele</surname>
            , and
            <given-names>T.</given-names>
          </string-name>
          <string-name>
            <surname>Westmann</surname>
          </string-name>
          .
          <article-title>Anatomy of a native xml base management system</article-title>
          .
          <source>VLDB Journal</source>
          ,
          <volume>11</volume>
          (
          <issue>4</issue>
          ):
          <fpage>292</fpage>
          -
          <lpage>314</lpage>
          ,
          <year>2002</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          13.
          <string-name>
            <given-names>J.</given-names>
            <surname>Gray</surname>
          </string-name>
          and
          <string-name>
            <given-names>A.</given-names>
            <surname>Reuter</surname>
          </string-name>
          . Transaction Processing :
          <article-title>Concepts and Techniques</article-title>
          . Morgan Kaufmann Publishers,
          <source>1st edition</source>
          ,
          <year>1993</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          14.
          <string-name>
            <given-names>M. P.</given-names>
            <surname>Haustein</surname>
          </string-name>
          and
          <string-name>
            <surname>T.</surname>
          </string-name>
          <article-title>H¨arder. A synchronization concept for the DOM API</article-title>
          . In H. H¨opfner, G. Saake, and E. Schallehn, editors,
          <source>Grundlagen von Datenbanken</source>
          , pages
          <fpage>80</fpage>
          -
          <lpage>84</lpage>
          . Fakult¨at fu¨r Informatik,
          <source>Universit¨at Magdeburg</source>
          ,
          <year>2003</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          15.
          <string-name>
            <given-names>M. P.</given-names>
            <surname>Haustein</surname>
          </string-name>
          and
          <string-name>
            <surname>T.</surname>
          </string-name>
          <article-title>H¨arder. An efficient infrastructure for native transactional XML processing</article-title>
          . Data Knowl. Eng.,
          <volume>61</volume>
          (
          <issue>3</issue>
          ):
          <fpage>500</fpage>
          -
          <lpage>523</lpage>
          ,
          <year>2007</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref16">
        <mixed-citation>
          16.
          <string-name>
            <surname>M. P. Haustein</surname>
            , T. H¨arder, C. Mathis, and
            <given-names>M. W.</given-names>
          </string-name>
          <year>0002</year>
          .
          <article-title>Deweyids - the key to fine-grained management of xml documents</article-title>
          . In C. A. Heuser, editor,
          <source>SBBD</source>
          , pages
          <fpage>85</fpage>
          -
          <lpage>99</lpage>
          . UFU,
          <year>2005</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref17">
        <mixed-citation>
          17.
          <string-name>
            <given-names>P.</given-names>
            <surname>Loupal</surname>
          </string-name>
          .
          <article-title>Updating typed XML documents using a functional data model</article-title>
          . In J. Pokorny´,
          <string-name>
            <surname>V.</surname>
          </string-name>
          <article-title>Sn´aˇsel, and</article-title>
          K. Richta, editors,
          <source>DATESO</source>
          , volume
          <volume>235</volume>
          <source>of CEUR Workshop Proceedings. CEUR-WS.org</source>
          ,
          <year>2007</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref18">
        <mixed-citation>
          18.
          <string-name>
            <surname>M. Nicola</surname>
            ,
            <given-names>I. Kogan</given-names>
          </string-name>
          , and
          <string-name>
            <given-names>B.</given-names>
            <surname>Schiefer</surname>
          </string-name>
          .
          <article-title>An xml transaction processing benchmark</article-title>
          .
          <source>In SIGMOD '07: Proceedings of the 2007 ACM SIGMOD international conference on Management of data</source>
          , pages
          <fpage>937</fpage>
          -
          <lpage>948</lpage>
          , New York, NY, USA,
          <year>2007</year>
          . ACM Press.
        </mixed-citation>
      </ref>
      <ref id="ref19">
        <mixed-citation>
          19.
          <string-name>
            <surname>J. Pokorny</surname>
          </string-name>
          <article-title>´. XML functionally</article-title>
          . In B. C. Desai,
          <string-name>
            <given-names>Y.</given-names>
            <surname>Kioki</surname>
          </string-name>
          , and M. Toyama, editors,
          <source>Proceedings of IDEAS2000</source>
          , pages
          <fpage>266</fpage>
          -
          <lpage>274</lpage>
          . IEEE Comp. Society,
          <year>2000</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref20">
        <mixed-citation>
          20.
          <string-name>
            <surname>J. Pokorny</surname>
          </string-name>
          <article-title>´. XML-λ: an extendible framework for manipulating XML data</article-title>
          .
          <source>In Proceedings of BIS 2002</source>
          , pages
          <fpage>160</fpage>
          -
          <lpage>168</lpage>
          , Poznan,
          <year>2002</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref21">
        <mixed-citation>
          21.
          <string-name>
            <given-names>A.</given-names>
            <surname>Siirtola</surname>
          </string-name>
          and
          <string-name>
            <given-names>M.</given-names>
            <surname>Valenta</surname>
          </string-name>
          .
          <article-title>Verifying parameterized taDOM+ lock managers</article-title>
          .
          <source>SOFSEM</source>
          <year>2008</year>
          , pages
          <fpage>460</fpage>
          -
          <lpage>472</lpage>
          ,
          <year>2008</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref22">
        <mixed-citation>
          22.
          <string-name>
            <given-names>P.</given-names>
            <surname>Strnad</surname>
          </string-name>
          and
          <string-name>
            <given-names>M.</given-names>
            <surname>Valenta</surname>
          </string-name>
          .
          <article-title>Object-oriented Implementation of Transaction Manager in CellStore Project</article-title>
          .
          <source>Objekty</source>
          <year>2006</year>
          , Praha, pages
          <fpage>273</fpage>
          -
          <lpage>283</lpage>
          ,
          <year>2006</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref23">
        <mixed-citation>
          23.
          <article-title>The W3C Consortium. W3C homepage</article-title>
          . http://www.w3.org.
        </mixed-citation>
      </ref>
      <ref id="ref24">
        <mixed-citation>
          24.
          <article-title>The W3C Consortium</article-title>
          .
          <source>Document Object Model (DOM)</source>
          ,
          <year>2005</year>
          . http://www.w3.org/DOM/.
        </mixed-citation>
      </ref>
      <ref id="ref25">
        <mixed-citation>
          25. J. Vrany´.
          <article-title>Cellstore - the vision of pure object database</article-title>
          . In V. Sn´asel, K. Richta, and J. Pokorny´, editors,
          <source>DATESO</source>
          , volume
          <volume>176</volume>
          <source>of CEUR Workshop Proceedings. CEUR-WS.org</source>
          ,
          <year>2006</year>
          .
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>