IP Library Granted Patent US 8,271,448
Granted Patent B2
US 8,271,448 · App. 11/044,267 · Granted Sep 18, 2012

Method for strategizing protocol presumptions in two phase commit coordinator

Assignee: Oracle International Corporation
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 8,271,448
App. No.
11/044,267
Granted
Sep 18, 2012
Kind
B2
Abstract

A transaction processing system provides the capability to use one two-phase commit engine over multiple protocols and products, while being able to vary the log presumptions according to the requirements of each protocol and product. The transaction processing system comprises a coordinator operable to receive a commit or abort request from a transaction and to perform a two-phase commit protocol on behalf of the transaction and a recovery presumption mechanism operable to perform a recovery process on the transaction upon recovery of the transaction processing system from a failure.

Claims (32)

1. A transaction processing system comprising:

a processor to execute computer program instructions;

a memory to store the computer program instructions executable by the processor; and

the computer program instructions stored in the memory and executable to implement:

a coordinator receiving a commit or abort request for a transaction and performing a two-phase commit protocol on behalf of the transaction; and

one unit for transaction logging writing log information pertaining to a transaction for use upon recovery of the transaction from a failure in which a result of the two-phase commit protocol for the transaction is incomplete or undetermined, the one unit for transaction logging comprising:

a strategy pattern interchangeably encapsulating all of a plurality of log presumption strategies used by the one unit for transaction logging to create statically or dynamically pluggable presumptions about the recovery semantics of the two-phase commit protocol,

wherein the plurality of interchangeably encapsulated log presumption strategies includes a strategy that proceeds as though the result of the two-phase commit protocol for the transaction is that the transaction was aborted, a strategy that proceeds as though the result of the two-phase commit protocol for the transaction is that the transaction was committed, and a strategy that obtains further information relating to the result of the two-phase commit protocol for the transaction before proceeding;

wherein the strategy pattern is operable to select a log presumption strategy from among the plurality of log presumption strategies and the transaction processing system further comprises a transaction logging unit writing to a log information relating to the transaction based upon the selected log presumption strategy; and

wherein if the selected log presumption strategy is the strategy that obtains further information relating to the result of the two-phase commit protocol for the transaction before proceeding, the transaction logging unit writes to a log information relating to the transaction when the transaction is created, writes to a log information relating to the transaction after a state change of the two-phase protocol, and purging the information relating to the transaction from the log when the transaction is completed.

2. The transaction processing system of claim 1 , wherein if the selected log presumption strategy is the strategy that proceeds as though the result of the two-phase commit protocol for the transaction is that the transaction was aborted, the transaction logging unit writes to a log information relating to the transaction when coordinator has begun a committing phase of the two-phase commit protocol.

3. In a transaction processing system, a method of transaction processing comprising:

receiving, by a computer processor, a commit or abort request from a transaction;

performing a two-phase commit protocol on behalf of the transaction;

recovering from a failure of the transaction processing or a transactional participant resource system that causes a result of the two-phase commit protocol for the transaction to be incomplete or to be undetermined by performing a recovery process on the transaction, the recovery process performed using log information written by one unit for transaction logging comprising:

providing a strategy pattern interchangeably encapsulating all of a plurality of log presumption strategies used by the one unit for transaction logging to create statically or dynamically pluggable presumptions about the recovery semantics of the two-phase commit protocol,

wherein the plurality of interchangeably encapsulated log presumption strategies includes a strategy that proceeds as though the result of the two-phase commit protocol for the transaction is that the transaction was aborted, a strategy that proceeds as though the result of the two-phase commit protocol for the transaction is that the transaction was committed, and a strategy that obtains further information relating to the result of the two-phase commit protocol for the transaction before proceeding;

further comprising selecting a log presumption strategy from among the plurality of log presumption strategies and writing to a log information relating to the transaction based upon the selected log presumption strategy; and

wherein if the selected log presumption strategy is the strategy that obtains further information relating to the result of the two-phase commit protocol for the transaction before proceeding, the transaction logging unit writes to a log information relating to the transaction when the transaction is created, writes to a log information relating to the transaction after a state change of the two-phase protocol, and purges the information relating to the transaction from the log when the transaction is completed.

4. The method of claim 3 , wherein if the selected log presumption strategy is the strategy that proceeds as though the result of the two-phase commit protocol for the transaction is that the transaction was aborted, the transaction logging unit writes to a log information relating to the transaction when coordinator has begun a committing phase of the two-phase commit protocol.

5. The system of claim 1 , wherein the transaction logging unit performs a log presumption strategy based on dynamic selection of the strategy based on capabilities of transaction participants.

6. The method of claim 3 , wherein the recovery process further comprises performing a log presumption strategy based on dynamic selection of the strategy based on capabilities of transaction participants.

7. A computer program product for performing transaction processing in a transaction processing system, the computer program product comprising a non-transitory computer-readable storage medium having computer program instructions recorded thereon, the computer program instructions executable by a processor for performing:

receiving a commit or abort request from a transaction;

performing a two-phase commit protocol on behalf of the transaction;

recovering from a failure of the transaction processing or a transactional participant resource system that causes a result of the two-phase commit protocol for the transaction to be incomplete or to be undetermined by performing a recovery process on the transaction, the recovery process performed using log information written by one unit for transaction logging comprising:

providing a strategy pattern interchangeably encapsulating all of a plurality of log presumption strategies used by the one unit for transaction logging to create statically or dynamically pluggable presumptions about the recovery semantics of the two-phase commit protocol,

wherein the plurality of interchangeably encapsulated log presumption strategies includes a strategy that proceeds as though the result of the two-phase commit protocol for the transaction is that the transaction was aborted, a strategy that proceeds as though the result of the two-phase commit protocol for the transaction is that the transaction was committed, and a strategy that obtains further information relating to the result of the two-phase commit protocol for the transaction before proceeding;

further comprising selecting a log presumption strategy from among a plurality of log presumption strategies and writing to a log information relating to the transaction based upon the selected log presumption strategy; and

wherein if the selected log presumption strategy is the strategy that obtains further information relating to the result of the two-phase commit protocol for the transaction before proceeding, the transaction logging unit writes to a log information relating to the transaction when the transaction is created, writes to a log information relating to the transaction after a state change of the two-phase protocol, and purges the information relating to the transaction from the log when the transaction is completed.

8. The computer program product of claim 7 , wherein if the selected log presumption strategy is the first strategy that proceeds as though the result of the two-phase commit protocol for the transaction is that the transaction was aborted, the transaction logging unit writes to a log information relating to the transaction when coordinator has begun a committing phase of the two-phase commit protocol.

9. The computer program product of claim 7 , wherein the recovery process further comprises performing a log presumption strategy based on dynamic selection of the strategy based on capabilities of transaction participants.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 28, 2005
From: PARKINSON, PAUL; PAVLIK, GREG
To: ORACLE INTERNATIONAL CORPORATION
Reel/Frame 016225/0628 →
Continuity (1)
Related Publication 20060174224A1 · Aug 3, 2006