100 likes | 133 Views
Term Project. Topic: Mobile Distributed Transaction Commit Protocol – A Survey Student: Jaman L. Bhola Lecturer: Dr. S. Prasad Class: CSc 8530 Date: 4/20/04. Introduction.
E N D
Term Project Topic: Mobile Distributed Transaction Commit Protocol – A Survey Student: Jaman L. Bhola Lecturer: Dr. S. Prasad Class: CSc 8530 Date: 4/20/04
Introduction • Mobile units are more widespread today and will become even more dominant in the future over fixed units. • This being the case, the design to support mobile units must be more robust and reliable. • Overall, be they fixed or mobile units, connections need to be established and maintained
Mainly because databases are being manipulated – records are either added, edited or deleted. • But because mobile units suffer major disconnections – battery goes dead, wireless connection went dead, static, etc. manipulating databases become even more important. • The following diagram shows a typical architecture for mobile and fixed units.
MC MSS MSS MSS The Architecture: Cells MC MC Fixed Wired Network Fixed Host Local DBMS Fixed Host Local DBMS MSS: Mobile Support Station MC: Mobile Client
The transaction • Most systems use either the 2PC or 3PC (the 2 phase commit protocol, or the 3 phase commit protocol, respectively). • The difference is that in the case of the 3PC, when a MC wants to commit data, it will make a request to the MSS (Phase 1). • The MSS in turn will send a “prepare” message for such commit to MCs’ (Phase 2). • After receiving an acknowledgement from MCs’, MSS prepare for Commit. (Phase 3)
During phase 1, initially the coordinator sends a query to commit message to all cohorts. Then it waits for all cohorts to report back with the agreement message. The cohorts, if the transaction was successful, write an entry to the undo log and an entry to the redo log. Then the cohorts reply with an agree message, or an abort if the transaction failed at a cohort node.
During phase 2, if the coordinator receives an agree message from all cohorts, then it writes a commit record into its log and sends a commit message to all the cohorts. If all agreement messages do not come back the coordinator sends an abort message. Next the coordinator waits for the acknowledgement from the cohorts. When acks are received from all cohorts the coordinator writes a complete record to its log. Note the coordinator will wait forever for all the acknowledgements to come back. If the cohort receives a commit message, it releases all the locks and resources held during the transaction and sends an acknowledgement to the coordinator. If the message is abort, then the cohort undoes the transaction with the undo log and releases the resources and locks held during the transaction. Then it sends an acknowledgement.
Models • Many of the models surveyed either use algorithms for the 2PC or 3PC. • Some models are: 1. PRO-MOTION 2. Moflex Transaction Model 3. Kangaroo 4. Nested Transaction Model 5. Open nested transaction model • These are only some of the models surveyed
These various models are investigated and compared with each other to perhaps find those that may seem to be better.