Verfahren und Vorrichtung um eine verteilte Transaktion in einer verteilten Datenbank auszuführen

The present invention describes a method and apparatus that forces all parts of an update transaction to commit automatically using a two-phase commit. The present invention uses the two-phase commit messages to negotiate a system commit number (SCN) that is then recorded on each of the nodes as the...

Ausführliche Beschreibung

Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: BAMFORD, ROGER, HALLMARK, GARY
Format: Patent
Sprache:ger
Schlagworte:
Online-Zugang:Volltext bestellen
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
Beschreibung
Zusammenfassung:The present invention describes a method and apparatus that forces all parts of an update transaction to commit automatically using a two-phase commit. The present invention uses the two-phase commit messages to negotiate a system commit number (SCN) that is then recorded on each of the nodes as the logical point in time that the distributed transaction committed. The two-phase commit scheme of the present invention consists of a "prepare" phase and a "commit" phase. The transaction in the distributed database environment involves multiple participants (107A,...,107N) (databases). In the prepare phase, one of the N database participants (107N) is selected as the "commit point". The commit point (107N) includes the log (106N) into which the information is written that states the transaction has committed. The remaining N - 1 participants (107A,...,107N-1) enter a "prepare phase." In the prepare phase, the prepare participants lock their databases (105A,...,105N-1) and enter a state in which they are ready to roll back or commit to the transaction. The mid-point of the two-phase commit is the point at which the commit point database (105N) (nth participant) writes the commit transaction to its log (106N). In the second phase, the remaining participants (107A,...,107N-1) are informed to commit the transaction and release locks that have been set.