• Keine Ergebnisse gefunden

Quiz Sheet No. 3 for

N/A
N/A
Protected

Academic year: 2022

Aktie "Quiz Sheet No. 3 for"

Copied!
2
0
0

Wird geladen.... (Jetzt Volltext ansehen)

Volltext

(1)

Quiz Sheet No. 3 for Architecture and Implementation of Database Systems Prof. Rudolf Bayer, Ph. D.

Institut für Informatik SS 2003

Exercises for Chapters 4.2 – 4.7: Serializability and Synchronization

1. Let H: r1(y), r3(n), r2(y), w1(y), r1(x), w1(x), r2(x), r2(z), w2(z), r3(x), w3(x)

be a schedule of three transactions t1, t2 and t3 that are accessing objects n, x, y and z.

a) Write the sequence of actions for each transaction t1, t2 and t3. b) Determine the conflict relation confH.

c) Sketch the corresponding conflict graph using the “follow relation” (defined in chapter 4.3 on page11).

d) Is schedule H conflict serializable?

2. Let t1, t2 and t3 be three transactions that are defined in the following way:

t1 = (bot, r(u), r(y), w(y), r(z), w(z), w(u), eot) t2 = (bot, r(z), r(u), r(y), w(z), eot)

t3 = (bot, r(z), r(y), r(u), w(u), eot)

a) Compute conf for the set of operations in t1, t2 and t3. b) Consider the following schedule H1:

timeline

Determine the relation confH1 for schedule H1.

t1 t2 t3

r(u) r(y)

r(z) r(u) w(y)

r(z) r(y) r(y)

r(z) w(z)

r(u) w(u) w(u)

w(z)

(2)

c) Consider a second schedule H2:

t1 t2 t3

r(u)

r(z) r(y)

r(u) r(y) w(y)

w(z) r(z)

w(z)

r(z) r(y) w(u)

r(u) w(u)

Show that H2 is conflict serializable.

d) Describe some possibilities for modifying H2 to a new schedule H3, so that H3 is also serializable.

e) List the lock requests for each transaction t1, t2 and t3 according to the (R,A,X) protocol.

3. Assume optimistic concurrency control (OCC) regarding this schedule:

t1 t2

bot

bot r(x)

r(y)

r(z) w(x)

w(z) eot

r(x) eot

a) Determine the ReadSet and WriteSet of each transaction.

b) What will happen to transaction t2 in this execution order? Why?

Referenzen

ÄHNLICHE DOKUMENTE

Der Trainer erklärt dem Kind, was es in die einzelnen Felder malen soll, so dass sich das.. Bild vom Hasen ergibt, oder er legt das Original dem Kind vor und das Kind überträgt

[r]

[r]

It is shown that these results qualitatively follow the previously found ones for the inverse squared potential where explicit analytic solutions are known. Key words:

To the left the phonon dispersion relation by plotting the frequency as a function of the group velocity is shown, and to the right the soliton dis- persion relation by plotting

In what follows, it will be important to distinguish between two issues that have tended to overlap in Pauline studies in the past but now are increasingly diverging from one

It is possible to transform any SAT formula F into k-colorable graph, generate a graph G = (V,E) with number of colors k, such that G is k-colorable only in the case of F

[r]