SlideShare a Scribd company logo
1 of 13
11/12/97 M-1
Schedules and Serializability
17.4-17.5
11/12/97 M-2
Schedules
• A "schedule" is the abstraction of the
activity of simultaneous transactions.
• Everything is stripped away except:
– transaction identifiers (as subscripts)
– DB READs and WRITEs and the data they
operate on
– COMMITs and ABORTs
– The order of these operations
11/12/97 M-3
Schedule Notation
• Sa A schedule of one or more transactions
• Ti A transaction.
• ri(X) Transaction Ti performs a READ
of data item X.
• wi(X) Transaction Ti performs a WRITE
of data item X.
• ai Transaction i aborts.
• ci Transaction i commits.
11/12/97 M-4
Serial Schedules
• If Ti does not overlap Tj, ACID behavior is
assured.
– Notation: Ti;Tj means Ti executes fully, then Tj
executes
– Called a "serial" schedule
• T1;T2;T3 and T2;T3;T1 might have different
results, but either is acceptable.
11/12/97 M-5
Serializable Schedules
• Serial schedules, though safe, are
unacceptably costly
– Transactions are I/O-bound (most elapsed time
is spent waiting for I/O)
• Non-serial (overlapped) schedules allow
shorter turn-around and better resource
utilization
• A serializable schedule is one which is
equivalent to some serial schedule
11/12/97 M-6
Schedules and Serializability
Theory
• Schedules are a major tool in studying
concurrent processing of transactions
• Goals:
– be able to recognize when a schedule is
serializable
and/or:
– be able to force schedules to be serializable
and/or
– be able to recognize when a schedule is
recoverable if an abort occurs
11/12/97 M-7
Conflicts
• A conflict occurs when one transaction in a
schedule WRITEs a data item which
another transaction also uses (READs or
WRITEs)
– Note: no order requirement in this definition
– The two operations are said to conflict
– The two Ts are also said to conflict
– A conflict per se is not a show-stopper
11/12/97 M-8
Recoverability
• The TP monitor must have the power to
undo or "rollback" the effect of a
transaction.
– Example: if a transaction aborts after doing
some WRITE
• If one transaction in a schedule aborts, it
may be necessary to abort and rollback
others.
– committed transactions should never be rolled
back
11/12/97 M-9
Recoverable Schedules
• Ti reads from Tj (with respect to a schedule)
if Ti READs some item which had
previously been WRITten by Tj.
• A schedule is recoverable if no transaction
in it COMMITs until all transactions that it
READs from have COMMITted.
• Stronger: in a strict schedule, a transaction
cannot even read or write X until the last
transaction which wrote X has
COMMITted.
11/12/97 M-10
Recognizing Serializability
• In general, difficult or impossible
– depends on the semantics of the transactions
• Some forms of serializability can be
detected
• Two schedules are conflict equivalent if the
order of any two conflicting operations is
the same in both schedules.
11/12/97 M-11
Conflict Serializability
• A schedule is conflict serializable if there is
some serial schedule with which it is
conflict equivalent.
• Turns out there's a simple algorithm to test
for conflict serializability!
– Make a digraph ("precedence graph") of the T's
– Directed edges mark conflicts
Theorem: schedule is conflict serializable iff
graph has no cycles.
11/12/97 M-12
Granularity Issues
• Granularity refers to the size of the data
being read or written
– whole DB; table; row; one attribute value, etc.
• Smaller granularity means more
concurrency, but more overhead
• DBMSs differ in granularity supported
• Transaction semantics may determine
needed granularity
11/12/97 M-13
Not the Final Word
• There are schedules which are not conflict
serializable, but still serializable
– "View serializability" is another definition;
harder to check but allows more cases
• There are even schedules which are not
serializable but nevertheless safe
• Serializability is a tool for analysis, not a
prescription.

More Related Content

Similar to m-serial.ppt

Characteristics Schedule based on Recover-ability & Serial-ability
Characteristics Schedule based on Recover-ability & Serial-abilityCharacteristics Schedule based on Recover-ability & Serial-ability
Characteristics Schedule based on Recover-ability & Serial-abilityMeghaj Mallick
 
Database ,11 Concurrency Control
Database ,11 Concurrency ControlDatabase ,11 Concurrency Control
Database ,11 Concurrency ControlAli Usman
 
Transaction and serializability
Transaction and serializabilityTransaction and serializability
Transaction and serializabilityYogita Jain
 
DBMS_Transaction processing – Schedule –Serializable Schedule – Concurrency C...
DBMS_Transaction processing – Schedule –Serializable Schedule – Concurrency C...DBMS_Transaction processing – Schedule –Serializable Schedule – Concurrency C...
DBMS_Transaction processing – Schedule –Serializable Schedule – Concurrency C...DrThenmozhiKarunanit
 
Transactions in dbms
Transactions in dbmsTransactions in dbms
Transactions in dbmsNancy Gulati
 
UNIT 2- TRANSACTION CONCEPTS AND CONCURRENCY CONCEPTS (1).pdf
UNIT 2- TRANSACTION CONCEPTS AND CONCURRENCY CONCEPTS (1).pdfUNIT 2- TRANSACTION CONCEPTS AND CONCURRENCY CONCEPTS (1).pdf
UNIT 2- TRANSACTION CONCEPTS AND CONCURRENCY CONCEPTS (1).pdfKavitaShinde26
 
Adbms 35 recoverability and serializability
Adbms 35 recoverability and serializabilityAdbms 35 recoverability and serializability
Adbms 35 recoverability and serializabilityVaibhav Khanna
 
recoverability and serializability dbms
recoverability and serializability  dbmsrecoverability and serializability  dbms
recoverability and serializability dbmsKumari Naveen
 
db unit 4 dbms protocols in transaction
db unit 4 dbms  protocols in transactiondb unit 4 dbms  protocols in transaction
db unit 4 dbms protocols in transactionKumari Naveen
 
concurrencycontrol_databasemanagement_system
concurrencycontrol_databasemanagement_systemconcurrencycontrol_databasemanagement_system
concurrencycontrol_databasemanagement_systemDeepaliKonety
 
concurrencycontrol from power pint pdf a
concurrencycontrol  from power pint pdf aconcurrencycontrol  from power pint pdf a
concurrencycontrol from power pint pdf aMdAyanParwez
 
TRANSACTION MANAGEMENT AND TIME STAMP PROTOCOLS AND BACKUP RECOVERY
TRANSACTION MANAGEMENT AND TIME STAMP PROTOCOLS AND BACKUP RECOVERYTRANSACTION MANAGEMENT AND TIME STAMP PROTOCOLS AND BACKUP RECOVERY
TRANSACTION MANAGEMENT AND TIME STAMP PROTOCOLS AND BACKUP RECOVERYRohit Kumar
 
3 concurrency controlone_v3
3 concurrency controlone_v33 concurrency controlone_v3
3 concurrency controlone_v3ashish61_scs
 

Similar to m-serial.ppt (20)

Characteristics Schedule based on Recover-ability & Serial-ability
Characteristics Schedule based on Recover-ability & Serial-abilityCharacteristics Schedule based on Recover-ability & Serial-ability
Characteristics Schedule based on Recover-ability & Serial-ability
 
Database ,11 Concurrency Control
Database ,11 Concurrency ControlDatabase ,11 Concurrency Control
Database ,11 Concurrency Control
 
Transaction and serializability
Transaction and serializabilityTransaction and serializability
Transaction and serializability
 
DBMS_Transaction processing – Schedule –Serializable Schedule – Concurrency C...
DBMS_Transaction processing – Schedule –Serializable Schedule – Concurrency C...DBMS_Transaction processing – Schedule –Serializable Schedule – Concurrency C...
DBMS_Transaction processing – Schedule –Serializable Schedule – Concurrency C...
 
Lec08
Lec08Lec08
Lec08
 
Transactions in dbms
Transactions in dbmsTransactions in dbms
Transactions in dbms
 
UNIT 2- TRANSACTION CONCEPTS AND CONCURRENCY CONCEPTS (1).pdf
UNIT 2- TRANSACTION CONCEPTS AND CONCURRENCY CONCEPTS (1).pdfUNIT 2- TRANSACTION CONCEPTS AND CONCURRENCY CONCEPTS (1).pdf
UNIT 2- TRANSACTION CONCEPTS AND CONCURRENCY CONCEPTS (1).pdf
 
Transactions
TransactionsTransactions
Transactions
 
Adbms 35 recoverability and serializability
Adbms 35 recoverability and serializabilityAdbms 35 recoverability and serializability
Adbms 35 recoverability and serializability
 
recoverability and serializability dbms
recoverability and serializability  dbmsrecoverability and serializability  dbms
recoverability and serializability dbms
 
Concurrency control
Concurrency control Concurrency control
Concurrency control
 
Concurrency control
Concurrency controlConcurrency control
Concurrency control
 
db unit 4 dbms protocols in transaction
db unit 4 dbms  protocols in transactiondb unit 4 dbms  protocols in transaction
db unit 4 dbms protocols in transaction
 
transaction_processing.ppt
transaction_processing.ppttransaction_processing.ppt
transaction_processing.ppt
 
concurrencycontrol_databasemanagement_system
concurrencycontrol_databasemanagement_systemconcurrencycontrol_databasemanagement_system
concurrencycontrol_databasemanagement_system
 
Concurrent Transactions.ppt
Concurrent Transactions.pptConcurrent Transactions.ppt
Concurrent Transactions.ppt
 
24904 lecture11
24904 lecture1124904 lecture11
24904 lecture11
 
concurrencycontrol from power pint pdf a
concurrencycontrol  from power pint pdf aconcurrencycontrol  from power pint pdf a
concurrencycontrol from power pint pdf a
 
TRANSACTION MANAGEMENT AND TIME STAMP PROTOCOLS AND BACKUP RECOVERY
TRANSACTION MANAGEMENT AND TIME STAMP PROTOCOLS AND BACKUP RECOVERYTRANSACTION MANAGEMENT AND TIME STAMP PROTOCOLS AND BACKUP RECOVERY
TRANSACTION MANAGEMENT AND TIME STAMP PROTOCOLS AND BACKUP RECOVERY
 
3 concurrency controlone_v3
3 concurrency controlone_v33 concurrency controlone_v3
3 concurrency controlone_v3
 

Recently uploaded

Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsJhone kinadey
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfproinshot.com
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionOnePlan Solutions
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionSolGuruz
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providermohitmore19
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...Health
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Steffen Staab
 
VTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learnVTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learnAmarnathKambale
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024Mind IT Systems
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesVictorSzoltysek
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...panagenda
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comFatema Valibhai
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdfPearlKirahMaeRagusta1
 

Recently uploaded (20)

Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
VTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learnVTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learn
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.com
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 

m-serial.ppt

  • 1. 11/12/97 M-1 Schedules and Serializability 17.4-17.5
  • 2. 11/12/97 M-2 Schedules • A "schedule" is the abstraction of the activity of simultaneous transactions. • Everything is stripped away except: – transaction identifiers (as subscripts) – DB READs and WRITEs and the data they operate on – COMMITs and ABORTs – The order of these operations
  • 3. 11/12/97 M-3 Schedule Notation • Sa A schedule of one or more transactions • Ti A transaction. • ri(X) Transaction Ti performs a READ of data item X. • wi(X) Transaction Ti performs a WRITE of data item X. • ai Transaction i aborts. • ci Transaction i commits.
  • 4. 11/12/97 M-4 Serial Schedules • If Ti does not overlap Tj, ACID behavior is assured. – Notation: Ti;Tj means Ti executes fully, then Tj executes – Called a "serial" schedule • T1;T2;T3 and T2;T3;T1 might have different results, but either is acceptable.
  • 5. 11/12/97 M-5 Serializable Schedules • Serial schedules, though safe, are unacceptably costly – Transactions are I/O-bound (most elapsed time is spent waiting for I/O) • Non-serial (overlapped) schedules allow shorter turn-around and better resource utilization • A serializable schedule is one which is equivalent to some serial schedule
  • 6. 11/12/97 M-6 Schedules and Serializability Theory • Schedules are a major tool in studying concurrent processing of transactions • Goals: – be able to recognize when a schedule is serializable and/or: – be able to force schedules to be serializable and/or – be able to recognize when a schedule is recoverable if an abort occurs
  • 7. 11/12/97 M-7 Conflicts • A conflict occurs when one transaction in a schedule WRITEs a data item which another transaction also uses (READs or WRITEs) – Note: no order requirement in this definition – The two operations are said to conflict – The two Ts are also said to conflict – A conflict per se is not a show-stopper
  • 8. 11/12/97 M-8 Recoverability • The TP monitor must have the power to undo or "rollback" the effect of a transaction. – Example: if a transaction aborts after doing some WRITE • If one transaction in a schedule aborts, it may be necessary to abort and rollback others. – committed transactions should never be rolled back
  • 9. 11/12/97 M-9 Recoverable Schedules • Ti reads from Tj (with respect to a schedule) if Ti READs some item which had previously been WRITten by Tj. • A schedule is recoverable if no transaction in it COMMITs until all transactions that it READs from have COMMITted. • Stronger: in a strict schedule, a transaction cannot even read or write X until the last transaction which wrote X has COMMITted.
  • 10. 11/12/97 M-10 Recognizing Serializability • In general, difficult or impossible – depends on the semantics of the transactions • Some forms of serializability can be detected • Two schedules are conflict equivalent if the order of any two conflicting operations is the same in both schedules.
  • 11. 11/12/97 M-11 Conflict Serializability • A schedule is conflict serializable if there is some serial schedule with which it is conflict equivalent. • Turns out there's a simple algorithm to test for conflict serializability! – Make a digraph ("precedence graph") of the T's – Directed edges mark conflicts Theorem: schedule is conflict serializable iff graph has no cycles.
  • 12. 11/12/97 M-12 Granularity Issues • Granularity refers to the size of the data being read or written – whole DB; table; row; one attribute value, etc. • Smaller granularity means more concurrency, but more overhead • DBMSs differ in granularity supported • Transaction semantics may determine needed granularity
  • 13. 11/12/97 M-13 Not the Final Word • There are schedules which are not conflict serializable, but still serializable – "View serializability" is another definition; harder to check but allows more cases • There are even schedules which are not serializable but nevertheless safe • Serializability is a tool for analysis, not a prescription.