Friday, April 2, 2010

Exercise 11: TP monitors and transaction protocols

1. Give a description in your own words of the ACID properties of a transaction.

The ACID properties of a transaction refer to Atomicity, Consisitency, Isolation and Durability. These are discussed in detail in Chapter 13 of Ince (2004). These properties have been developed to address one of the major proplems of a distributed system where clients may access a database concurrently. Each of these properties is defined briefly below.

  • Atomicity – This property refers the ability of a transaction to be fully processed and completed or canceled and rolled back. This is essentially an all or nothing rule. If one part of a given transaction fails, then the entire transaction fails.
  • Consistency – This means that only vaild data will be written to the database.If a given transaction violates a databases consistency rules, the entire transaction will be roled back and the database restored to its previous state.
  • Isolation – This requires that multiple transactions occurring at the same time not impact each other’s execution. Note that the isolation property does not ensure which transaction will execute first, merely that they will not interfere with each other.
  • Durability – This ensures that any transaction committed to the database will not be lost. Durability is ensured through the use of database backups and transaction logs that facilitate the restoration of committed transactions in spite of any subsequent software or hardware failures
2. Describe a TP monitor environment. How can a TP monitor stop an operating system being overwhelmed?

As stated in Ince (2004) a Transaction Processing (TP) monitor is a complex program which manages the execution of a transaction starting with the client executing the transaction. A TP monitor environment is normally put in place when a system handles many multi-threaded processes such as distributed client/server systems where all transactions must ensure that ACID properties are enforced. TP monitors effectively address the problem of hundreds or thousands of users accessing shared databases concurrently. In the absence on such an environement, there would be degradation of any system which supported them and data can be maliciously damaged, altered or lost.

As described in Ince (2004) a TP monitor may carry out numerous fimctions oincluding initating and destroyng threads to carry out transaciotnal operations, manage resources that are being accessed, ensure that if a transaction fails then suitable action is taken, schedule threads based on priority, enable the processing load on a distributed system to be shared over a number of server and ultimately enable a distributed system to function. A TP monitor can prevent an operating system being overwhelmed by scheduling threads and processes appropriately and evenly distributing the processing load. In undertaking these load distrubition and prioritsation functions, a TP system effectively prevent an operating system from being overwhelmed.

No comments:

Post a Comment