/    /  DBMS – Conflict Serializability

Conflict Serializability

There are two types of conflicts. In this article, we are going to learn about Conflict Serializability. Before that, let’s see what both the conflicts are.

Conflict Equivalent: If a schedule-S can be transformed into a schedule-S’ by a series of non-conflicting instructions, then S and S’ are said to be ‘Conflict equivalent’.

Conflict Serializable: A schedule-S is said to be ‘conflict serializable’, if it is conflict equivalent to a serial schedule.

 

Example-1:   Create schedule-5 which is equivalent to schedule-3 part 3 of Transaction Isolation.

 

T1T2
read A;

write A;

read A;

write A;

read B;

write B;

read B;

write B;

By swapping the 4 and 5 instructions which are non-conflicting, we can get:

 

T1T2
read A;

write A;

read A;
read B;
write A;
write B;
read B;

write B;

By swapping the 5 and 6 instructions which are non-conflicting, we can get schedule-6 (T1, T2) :

 

T1T2
read A;

write A;

read B;

write B;

read A;

write A;

read B;

write B;

This is equivalent to schedule-1.

 

 

 

Findings :

       Here, schedule-5 and schedule-1 are conflict equivalents.

          Here,  schedule-1 is a serial schedule.

       So,  schedule-5  is said to be conflict serializable.                          

       This concept is called ‘Conflict Serializability’.

 

Reference Links

Conflict Serializability