1/54
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
|---|
No study sessions yet.
Transaction
A unit of program execution that accesses and possibly updates database items.
ACID Properties
Set of properties ensuring reliable processing of transactions.
Atomicity
Ensures all operations of a transaction are completed or none at all.
Consistency
Ensures a transaction takes the database from one valid state to another.
Isolation
Ensures concurrent execution results match serial execution.
Durability
Ensures committed changes persist despite failures.
Transaction States
States through which every transaction passes during execution.
Active State
Transaction is executing read/write operations.
Partially Committed
State after final statement executed but before commit.
Committed
State after successful completion and commit.
Failed
State when normal execution cannot proceed.
Aborted
State when transaction is rolled back and database restored.
Serial Schedule
Schedule in which transactions execute one after another with no interleaving.
Concurrent Schedule
Schedule where instructions of different transactions are interleaved.
Conflict Serializable
Schedule equivalent to some serial schedule using conflict rules.
View Serializable
Schedule equivalent to a serial schedule based on reads/writes/views.
Conflicting Operations
Two operations conflict if they belong to different transactions and access same data with at least one write.
Recoverability
A schedule is recoverable if committed transactions never depend on uncommitted transactions.
Cascading Abort
If one transaction aborts, all dependent transactions also need to abort.
Cascadeless Schedule
Schedule where a transaction reads only committed values.
Strict Schedule
Schedule where writes/reads occur only after previous writes commit.
Concurrency Control
Methods to ensure correct execution of concurrent transactions.
Lock-Based Protocol
Protocol using shared and exclusive locks for controlling access.
Shared Lock (S-lock)
Allows transaction to read a data item.
Exclusive Lock (X-lock)
Allows transaction to read and write a data item.
Two-Phase Locking Protocol
Protocol where all locking happens before unlocking.
Growing Phase
Transaction obtains locks but does not release any.
Shrinking Phase
Transaction releases locks but cannot acquire new ones.
Strict 2PL
All exclusive locks held until commit; prevents cascading aborts.
Timestamp-Based Protocol
Uses timestamps to order transaction execution.
Wait-Die Scheme
Older transaction waits; younger transaction aborts.
Wound-Wait Scheme
Older transaction preempts younger; younger aborts.
Deadlock
Condition where two or more transactions wait for each other.
Deadlock Prevention
Ensures system never enters a deadlock state.
Deadlock Detection
System allows deadlock and periodically checks for cycles.
Deadlock Recovery
Process of aborting transactions to break deadlock.
Failure Classification
Types of failures affecting transaction execution.
Transaction Failure
Failure due to logical or arithmetic errors.
System Crash
Failure due to hardware/software crash.
Disk Failure
Failure due to disk corruption or bad sectors.
Log-Based Recovery
Uses a log to redo or undo transactions after failure.
Undo Logging
Writes
Redo Logging
Writes
Undo/Redo Logging
Writes both old and new values to log.
Checkpoint
A recovery mechanism that reduces amount of log scanned during recovery.
Shadow Paging
A recovery method using two page tables: shadow and current.
Before-Image
Value of data item before modification.
After-Image
Value of data item after modification.
Write-Ahead Logging
Rule ensuring log records are written before database updates.
Dirty Read
Read of a value written by an uncommitted transaction.
Starvation
Transaction waits indefinitely due to repeated rollbacks or delays.
Lost Update Problem
Two transactions overwrite each other’s updates.
Temporary Update Problem
Uncommitted updates visible to other transactions.
Incorrect Summary Problem
Inconsistent aggregated results due to interleaving.