Counter Powered by  RedCounter

Sabtu, 13 Desember 2008

Concurrency Control

It is the function of the transaction manager of a distributed database system to manage the execution of those transactions (or subtransactions) that access data store in a local site. Note that each such transaction may be either a local transaction (that is, transaction that only executes at that site) or part of a global transaction (that is, a trasaction that executes at several sites). Each transaction manager is responsible for maintaining a log for recovery purpose, and for participating in an appopriate concurrency-control scheme to coordinate the concurrent execution of the transactions executing at that site.

Locking Protocols
the only change that needs to be incorporated is in the way the lock manager is implemented. We present several possible schemes, the first of which deals with the case where no data replication is allowed. The other scheme are applicable to themore general case where data can be replicated in several sites.
If no data are replicated in the system. Each site maintains a local lock manager whose function is to administer the lock and unclock requests for those data items that are stored in that site. When a transaction wishes to lock data item Q at site Si, it simply sends a message to the lock manager at site Si requesting a lock (in a particular lock mode). If data item Q is locked in an incompatible mode, then the request is delayed until that request can be granted.
A.Failure Handling in 2PC

We now examine in detail how 2PC responds to various types of failures. As we shall see, one major disadvantage of the 2PC protocol is that coordinator failire may result in blocking, where a decision either to commit or to abort T may have to be postponed untul Ci recovers.

1.Failure of a Participating Site
When a participating site Sk recovers from a failure, it must examine its log to determine the fate of those transactions that were in the midst of execution when the failure occureed. Let T be one suck transaction. We consider each of the possible cases:
The log contains a record. In this case, the site executes redo(T).
The log contains an . in this In this case, the site executes undo(T).
The log contains a record. In this case, the site must consult Ci to determine the fate of T. if Ci is up, it notifies Sk regarding whether T committed or aborted. In the former case, it executes redo(T):in the latter case, it executes undo(T). if Ci is down, Sk must try to find the fate of T from other sites. It does so by sending a query-status T massage to all the sites in the system. On receiving such a message, a site must consult its log to determine whether T has executed there, and if so, whether T committed or aborted. It then notifies Sk about this outcome. It no site has the apporopriate information (that is, whether T committed or aborted), then Sk can neither abort nor commit T. The decision concerting T is postponod until Sk can obtain the needed information. Thus, Sk must periodically resend the query-status mwssage to the other sites. It does so until a site recovers that contains the needed information. Note that the site at which Ci resides always has the needed information.
The log contains no control records (abort, commit, ready) concerning T. Theabsence of control records implies that Sk failed before responding to the prepare T message from Ci. Since the failure of Sk precludes the sending of suck a response, by our olgorithm Ci must abotrt T. hence, Sk must execute undo(T).

2.Failure of the Coordinator
If the coordinator fails in the midst of the execution of the commit protocol for transaction T, then the participating sites must decide on the fate of T. we shall see that, in certain cases, the participating sites cannot decide whether to commit or abort T, and therefore it is necessary for these sites to wait for the recovery of the failed coordinator.
If an active site contains a record in its log, then T must be committed.
If an active site contains a record in its log, then T must be aborted.
If some active site does not contain a record in its log, then the failed coordinator Ci cannot have decided to commit T. We can draw this conclusion because a site that does not have a record in its log cannot have sent a ready T message to Ci. However, the coordinator may have decided to abort T, but not to commit T. Rather that wait for Ci to recover, it is preferable to abort T.
If none of the preceding cases holds, then all active sites must have a record in their logs, but no additional control (such as or ). Since the coordinator has failed, it is impossible to determine whether a decision has been made, or what that decision is, until the coordinator recovers. Thuis, the active sites must wait for Ci to recover. Since the fate of T remain in doubt, T may continue to hold system resource. For exemple, if locking is used, T may hold lock on data at active sites. Suck a situation is undesirable because it may take hours or days before Ci is again active. During this time other transaction may be forced to nwait for T. as a result, data are unavailable not only on the failed site (Ci) but on active sites as well. Tne number of unavailable data increase as he downtime of Ci grows. This situation is called the blocking problem, because T is blocked pending the recovery of site Ci.]

3.Failure of the Network
When alink fails, all the messages that are in the process of being routed through the link do not arrive at their destination intact. From the viewpoint of the sites connected throughout that link, it appears that the other sites have failed. Thus, our previous schemes apply here as well.
When a number of links fail, the network may partition. In this case, two possibilities exist. The coordinator and all its participant may remain in one partition: in this case, the failure has on effect on the commit protocol. Alternatively, the coordinator and its participants may belong to several partitions:in this case, message between the participant and the coordinator are lost, reducing the case a link failure, as discussed.
Left-handed people suffer more from stress that their right-handed peers, according to a study of 1.100 adults by University of Michigan researches. As a result, they smoke and drink more. Fifty-five percent of the lefties smoked, whereas fewer than half of the rigthies smoked. Furthermore, the lefties consumed more alcohol per year than their right-handed counterparts.


You ought to know what to do to help a person who is choking. First, you stand behind the choking victim and put your arms around his or her waist. Second, you make a fist and place the thumb side against the person’s stomach just above the navel, but below the ribs. Third, grasp your fist with your other hand and press into the victim’s abdomen with a qaick upward thrust. Repeat this action if necessary.


What’s the best way for you, as an employer, to deliver bad news to an employee? First of all, you have to break the news yourself, face to face with the recipient. You can’t write memos to tell people they will not get raises this year or that they have made an error or are not performing as well as expected. You have to show them how you feel about the matter that you are personally sorry and sympathize with them. If you indicate that you are ready to listen to theirreactions to your bad news, you will undoubtedly save yourself from their wraffth. Above all, you must be ready for an emotional reaction from the recipient of bad news. Give people time to digest your news and to control the emotion they invariably feel. Although it is neveer easy to break bad news, if you follow these steps, you will at soften the blow.

Yogurt has as much nutritional value as glass of milk, yet dieters and health food fanatics claim that yogurt will prolong your life and reduce your girth. Their claim are backed by reports that yogurt eaters over the years have lived longer and healtheir lives than non-yogurt eaters. However, what proof is there that rural are not the cause of these persons’ longevity?


Most of us believe that the dealth of a spouse often leads to the premature death of the bereft partner. After twelve years of study involving 4,000 windows and widowers, Johns Hopkins University researchers have perceived that it is the husbands, and not the wives, whose lives are shortened by the loss of their spouses. However, the study indicates that widowers who remarry enjoy greater longevity than men the same age who continue to live with their first wives.
Kinds Of Coffee

" Espresso

Diffraction referred by normale in Italian and is most popular coffee type. Representing pure coffee water with black colour and jell, and become making base many other coffee type. Presented in one-third or less than semi small cup. Can be drinked with or without sugar.

" Mocchiato

Come from he/she said mean to be smirched. Representing mixed Espresso meagrely hot spume or milk. Presented one-third or less than semi small cup. If its bigger cup, its name become cappuccino.

" Caffe Lette

Its Ianguage of him copy milk. Representing enhanced espresso with two or is rib of milk measuring times;rill of big pot which usually provided by in bar.

" Cappuccino

Representing enhanced by esspresso is hot milk which is spume. beverage of Classic for the breakfast of trusted Italian people more ' weight'. Best composition of him consist of one-third espresso, one-third hot usu and one-third foam sus which is condensed to be. Presented in larger ones cngkir of cup of espresso ordinary, is usually drinked with sugar.

" Marachino

It is said typical coffee of Moroccan having many devotee in Milan. In fact represent espresso added by hot milk spume and brown taburan of him. Presented in small cup

Senin, 24 November 2008

Minggu, 16 November 2008

  • Left-handed people suffer more from stress that their right-handed peers, according to a study of 1.100 adults by University of Michigan researches. As a result, they smoke and drink more. Fifty-five percent of the lefties smoked, whereas fewer than half of the rigthies smoked. Furthermore, the lefties consumed more alcohol per year than their right-handed counterparts.



  • You ought to know what to do to help a person who is choking. First, you stand behind the choking victim and put your arms around his or her waist. Second, you make a fist and place the thumb side against the person’s stomach just above the navel, but below the ribs. Third, grasp your fist with your other hand and press into the victim’s abdomen with a qaick upward thrust. Repeat this action if necessary.



  • What’s the best way for you, as an employer, to deliver bad news to an employee? First of all, you have to break the news yourself, face to face with the recipient. You can’t write memos to tell people they will not get raises this year or that they have made an error or are not performing as well as expected. You have to show them how you feel about the matter that you are personally sorry and sympathize with them. If you indicate that you are ready to listen to theirreactions to your bad news, you will undoubtedly save yourself from their wraffth. Above all, you must be ready for an emotional reaction from the recipient of bad news. Give people time to digest your news and to control the emotion they invariably feel. Although it is neveer easy to break bad news, if you follow these steps, you will at soften the blow.


  • Yogurt has as much nutritional value as glass of milk, yet dieters and health food fanatics claim that yogurt will prolong your life and reduce your girth. Their claim are backed by reports that yogurt eaters over the years have lived longer and healtheir lives than non-yogurt eaters. However, what proof is there that rural are not the cause of these persons’ longevity?



  • Most of us believe that the dealth of a spouse often leads to the premature death of the bereft partner. After twelve years of study involving 4,000 windows and widowers, Johns Hopkins University researchers have perceived that it is the husbands, and not the wives, whose lives are shortened by the loss of their spouses. However, the study indicates that widowers who remarry enjoy greater longevity than men the same age who continue to live with their first wives.