Movatterモバイル変換


[0]ホーム

URL:


Pratik Tambekar, profile picture
Uploaded byPratik Tambekar
PPT, PDF11,056 views

Distributed Transaction

This document discusses distributed transactions and the challenges of ensuring they satisfy the ACID properties of atomicity, consistency, isolation and durability even when transactions span multiple systems. It introduces the two-phase commit protocol, where a coordinator first polls participants if they can commit and then tells them to either commit or abort, addressing failures through durable logs and timeouts. While two-phase commit ensures all or nothing completion, it risks long blocks if the coordinator or participants fail.

Embed presentation

Downloaded 208 times
CS 603 Distributed Transactions February 18, 2002
What is a Transaction? • Atomic – The external view is that either everything in the transaction happened, or nothing did • Consistent – If the start state is valid, the end state is valid • Isolated – A transaction in process is not affected by and does not affect any other transaction • Durable – Once complete, the effects of a transaction are permanent, even in the event of failure.
Distributed Transactions • What is the difference with Distributed Transactions? – NOTHING! – Must still support ACID properties – Important for all the same reasons • Why do we study Distributed Transactions? – Some properties harder to implement – Basic single-system techniques not sufficient
What is a Distributed Transaction? Data Transaction component Transaction component Data Data Transaction component Transaction component Data
Why are Distributed Transactions Hard? • Atomic – Different parts of a transaction may be at different sites – How do we ensure all or none committed? • Consistent – Failure may affect only part of transaction • Isolated – Commitment must occur “simultaneously” at all sites • Durable – Not much different when other problems solved – Makes “delayed commit” difficult
Key Issues • Commitment – Standard techniques preserve properties when commit occurs – Distributed systems need commit protocols so we know when commit has occurred • Failures – Standard techniques support durability for commit/abort – What happens if a site fails during commitment?
Committing a Distributed Transaction Data Transaction component log Transaction component Data log Data Transaction component log Transaction component Data log
Two-Phase Commit (Lamport ’76, Gray ’79) • Assumes central coordinator – Coordinator initiates protocol – Participants: entities with actions to be committed/aborted • Phase 1: – Coordinator asks if participants can commit – Participants respond yes/no • Phase 2: – If all votes yes, coordinator sends Commit • Otherwise send Abort – Participants send Have Committed / Have Aborted
Two-Phase Commit Data Transaction component log Done Done Done Transaction component Data log Data Transaction component log Done Transaction component Data log CanCommit? CanCommit? Coordinator Commit CanCommit? CanCommit? Yes Yes Yes Yes Commit Commit Commit
Two-Phase Commit: Fault Tolerance • Participant fails in Phase 1: – Coordinator doesn’t get unanimous yes – Abort • Participant fails in Phase 2: – On reawakening, can ask coordinator if it should commit or abort – Requires that both commit and abort states be durable before sending “yes” vote
Two-Phase Commit: Problems • Blocks on failure – Timeout before abort if participant fails – All participants must wait for recovery if coordinator fails • While blocked, transaction must remain Isolated – Hold locks on data items touched – Prevents other transactions from completing • Solution: Wednesday

Recommended

PPTX
Application Layer
PPTX
Transactions and Concurrency Control
PPT
Distributed document based system
PPTX
Multicast routing protocols in adhoc networks
PPTX
Distributed file system
PPTX
Transport layer
PPT
Cloud deployment models
PPTX
Hadoop Distributed File System
PDF
Distributed deadlock
PDF
The CAP Theorem
PPTX
Transaction management DBMS
PPTX
Distributed Transactions(flat and nested) and Atomic Commit Protocols
PPT
Coda file system
PPTX
Distributed Mutual Exclusion and Distributed Deadlock Detection
PPTX
Distributed concurrency control
PPT
Communication primitives
PPTX
Distributed Query Processing
PPTX
Concurrency Control in Distributed Database.
PPTX
GOOGLE FILE SYSTEM
PDF
8. mutual exclusion in Distributed Operating Systems
PPT
Clock synchronization in distributed system
PPTX
Replication in Distributed Systems
PPTX
PPT
Transport services
PPT
Lamport’s algorithm for mutual exclusion
PPTX
Lec 7 query processing
PPTX
Network layer - design Issues
PDF
Agreement Protocols, distributed File Systems, Distributed Shared Memory
PPT
3 distributed transactions-cocurrency-query
PDF
Bab8 transaction

More Related Content

PPTX
Application Layer
PPTX
Transactions and Concurrency Control
PPT
Distributed document based system
PPTX
Multicast routing protocols in adhoc networks
PPTX
Distributed file system
PPTX
Transport layer
PPT
Cloud deployment models
PPTX
Hadoop Distributed File System
Application Layer
Transactions and Concurrency Control
Distributed document based system
Multicast routing protocols in adhoc networks
Distributed file system
Transport layer
Cloud deployment models
Hadoop Distributed File System

What's hot

PDF
Distributed deadlock
PDF
The CAP Theorem
PPTX
Transaction management DBMS
PPTX
Distributed Transactions(flat and nested) and Atomic Commit Protocols
PPT
Coda file system
PPTX
Distributed Mutual Exclusion and Distributed Deadlock Detection
PPTX
Distributed concurrency control
PPT
Communication primitives
PPTX
Distributed Query Processing
PPTX
Concurrency Control in Distributed Database.
PPTX
GOOGLE FILE SYSTEM
PDF
8. mutual exclusion in Distributed Operating Systems
PPT
Clock synchronization in distributed system
PPTX
Replication in Distributed Systems
PPTX
PPT
Transport services
PPT
Lamport’s algorithm for mutual exclusion
PPTX
Lec 7 query processing
PPTX
Network layer - design Issues
PDF
Agreement Protocols, distributed File Systems, Distributed Shared Memory
Distributed deadlock
The CAP Theorem
Transaction management DBMS
Distributed Transactions(flat and nested) and Atomic Commit Protocols
Coda file system
Distributed Mutual Exclusion and Distributed Deadlock Detection
Distributed concurrency control
Communication primitives
Distributed Query Processing
Concurrency Control in Distributed Database.
GOOGLE FILE SYSTEM
8. mutual exclusion in Distributed Operating Systems
Clock synchronization in distributed system
Replication in Distributed Systems
Transport services
Lamport’s algorithm for mutual exclusion
Lec 7 query processing
Network layer - design Issues
Agreement Protocols, distributed File Systems, Distributed Shared Memory

Similar to Distributed Transaction

PPT
3 distributed transactions-cocurrency-query
PDF
Bab8 transaction
PDF
Lec13s transaction
PDF
management of distributed transactions
PDF
module-4.1-Class notes_R and DD_basket-IV -.pdf
PDF
Management of Distributed Transactions
PPT
Transactions (Distributed computing)
PPTX
Distributed datababase Transaction and concurrency control
PPT
Chapter 13
PPTX
UNIT IV DIS.pptx
PDF
PPT
19. Distributed Databases in DBMS
PPTX
Unit iv -Transactions
PPTX
enc=encoded=TlJst0_SHq0cPRhLS74QDXTP4FpU303sSqpyVVkfhckA93UCiZrRF0QVNAFGmuGu9...
PPTX
Transaction management transparencies
PPTX
Unit v-Distributed Transaction and Replication
PPTX
UNIT II in the part of Database at the PG
PPT
4. concurrency control
PPT
A20 dfs2
PPTX
DBMS UNIT V.pptx
3 distributed transactions-cocurrency-query
Bab8 transaction
Lec13s transaction
management of distributed transactions
module-4.1-Class notes_R and DD_basket-IV -.pdf
Management of Distributed Transactions
Transactions (Distributed computing)
Distributed datababase Transaction and concurrency control
Chapter 13
UNIT IV DIS.pptx
19. Distributed Databases in DBMS
Unit iv -Transactions
enc=encoded=TlJst0_SHq0cPRhLS74QDXTP4FpU303sSqpyVVkfhckA93UCiZrRF0QVNAFGmuGu9...
Transaction management transparencies
Unit v-Distributed Transaction and Replication
UNIT II in the part of Database at the PG
4. concurrency control
A20 dfs2
DBMS UNIT V.pptx

More from Pratik Tambekar

PPTX
ASP DOT NET
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Distributed System by Pratik Tambekar
PPT
Data Mining Concepts and Techniques
PPT
What Is DATA MINING(INTRODUCTION)
PPT
World Wide Web(WWW)
PPTX
How To Add System Call In Ubuntu OS
ASP DOT NET
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Distributed System by Pratik Tambekar
Data Mining Concepts and Techniques
What Is DATA MINING(INTRODUCTION)
World Wide Web(WWW)
How To Add System Call In Ubuntu OS

Recently uploaded

PDF
application of matrix in computer science
PPT
Chapter 1-Week 4-General Thermodynamics-Introduction.ppt
PDF
Soil Permeability and Seepage-Irrigation Structures
PPTX
TRANSPORTATION ENGINEERING Unit-5.2.pptx
PPTX
Planning and selection of equipment for different mining conditions. Equipmen...
PDF
Welcome to ISPR 2026 - 12th International Conference on Image and Signal Pro...
PPTX
Mc25104 - data structures and algorithms using PYTHON OOP_Python_Lecture_Note...
PPTX
neural-networks-intro-basic-engineering.pptx
PPTX
31.03.24 - 7.CURRICULUM & TEACHING - LEARNING PROCESS IMPLEMENTATION DETAILS....
PDF
HEV Descriptive Questions https://www.slideshare.net/slideshow/hybrid-electr...
PDF
OOPCodesjavapracticalkabirpawarpptinparacticalexamination
PDF
Best Marketplaces to Buy Snapchat Accounts in 2025.pdf
PPTX
Intrusion Detection Systems presentation.pptx
PPTX
841726060-Ece-Software-Presentation.pptx
 
PPTX
Blockchain and cryptography Lecture Notes
PPTX
unit-1 Data structure (3).pptx Data structure And Algorithms
PDF
Chemical Bonding _ Class Notes.pdf for jee
PPTX
waste to energy deck v.3.pptx changing garbage to electricity
PDF
How-Forensic-Structural-Engineering-Can-Minimize-Structural-Failures.pdf
PPTX
TRANSPORTATION ENGINEERING Unit-5.1.pptx
application of matrix in computer science
Chapter 1-Week 4-General Thermodynamics-Introduction.ppt
Soil Permeability and Seepage-Irrigation Structures
TRANSPORTATION ENGINEERING Unit-5.2.pptx
Planning and selection of equipment for different mining conditions. Equipmen...
Welcome to ISPR 2026 - 12th International Conference on Image and Signal Pro...
Mc25104 - data structures and algorithms using PYTHON OOP_Python_Lecture_Note...
neural-networks-intro-basic-engineering.pptx
31.03.24 - 7.CURRICULUM & TEACHING - LEARNING PROCESS IMPLEMENTATION DETAILS....
HEV Descriptive Questions https://www.slideshare.net/slideshow/hybrid-electr...
OOPCodesjavapracticalkabirpawarpptinparacticalexamination
Best Marketplaces to Buy Snapchat Accounts in 2025.pdf
Intrusion Detection Systems presentation.pptx
841726060-Ece-Software-Presentation.pptx
 
Blockchain and cryptography Lecture Notes
unit-1 Data structure (3).pptx Data structure And Algorithms
Chemical Bonding _ Class Notes.pdf for jee
waste to energy deck v.3.pptx changing garbage to electricity
How-Forensic-Structural-Engineering-Can-Minimize-Structural-Failures.pdf
TRANSPORTATION ENGINEERING Unit-5.1.pptx

Distributed Transaction

  • 1.
    CS 603 DistributedTransactions February 18, 2002
  • 2.
    What is aTransaction? • Atomic – The external view is that either everything in the transaction happened, or nothing did • Consistent – If the start state is valid, the end state is valid • Isolated – A transaction in process is not affected by and does not affect any other transaction • Durable – Once complete, the effects of a transaction are permanent, even in the event of failure.
  • 3.
    Distributed Transactions •What is the difference with Distributed Transactions? – NOTHING! – Must still support ACID properties – Important for all the same reasons • Why do we study Distributed Transactions? – Some properties harder to implement – Basic single-system techniques not sufficient
  • 4.
    What is aDistributed Transaction? Data Transaction component Transaction component Data Data Transaction component Transaction component Data
  • 5.
    Why are DistributedTransactions Hard? • Atomic – Different parts of a transaction may be at different sites – How do we ensure all or none committed? • Consistent – Failure may affect only part of transaction • Isolated – Commitment must occur “simultaneously” at all sites • Durable – Not much different when other problems solved – Makes “delayed commit” difficult
  • 6.
    Key Issues •Commitment – Standard techniques preserve properties when commit occurs – Distributed systems need commit protocols so we know when commit has occurred • Failures – Standard techniques support durability for commit/abort – What happens if a site fails during commitment?
  • 7.
    Committing a DistributedTransaction Data Transaction component log Transaction component Data log Data Transaction component log Transaction component Data log
  • 8.
    Two-Phase Commit (Lamport’76, Gray ’79) • Assumes central coordinator – Coordinator initiates protocol – Participants: entities with actions to be committed/aborted • Phase 1: – Coordinator asks if participants can commit – Participants respond yes/no • Phase 2: – If all votes yes, coordinator sends Commit • Otherwise send Abort – Participants send Have Committed / Have Aborted
  • 9.
    Two-Phase Commit DataTransaction component log Done Done Done Transaction component Data log Data Transaction component log Done Transaction component Data log CanCommit? CanCommit? Coordinator Commit CanCommit? CanCommit? Yes Yes Yes Yes Commit Commit Commit
  • 10.
    Two-Phase Commit: FaultTolerance • Participant fails in Phase 1: – Coordinator doesn’t get unanimous yes – Abort • Participant fails in Phase 2: – On reawakening, can ask coordinator if it should commit or abort – Requires that both commit and abort states be durable before sending “yes” vote
  • 11.
    Two-Phase Commit: Problems• Blocks on failure – Timeout before abort if participant fails – All participants must wait for recovery if coordinator fails • While blocked, transaction must remain Isolated – Hold locks on data items touched – Prevents other transactions from completing • Solution: Wednesday

[8]ページ先頭

©2009-2025 Movatter.jp