Transaction processing system and method with reduced locking
First Claim
1. In a computerized data processing system having a plurality of data units, each data unit being identified by a respective first identifier which reflects an age not older than the age of the youngest modification of the data unit, a method of accessing a selected one of the data units by a selected one of a plurality of processes comprising the steps performed by the data processing system of:
- (a) maintaining a second identifier which reflects an age at least as old as the then-oldest in-process modification of a first plurality of the plurality of data units;
(b) comparing the second identifier with the selected data unit'"'"'s respective first identifier;
(c) obtaining access to the data unit for the selected process compatibly with other process'"'"' accesses to the data unit, said step of obtaining access being performed using fewer computer instructions if the selected data unit'"'"'s respective first identifier is older than the second identifier than if the selected data unit'"'"'s respective first identifier is not older than the second identifier; and
(d) reading the data unit by the selected process.
1 Assignment
0 Petitions
Accused Products
Abstract
Apparatus and method for reading data pages in a transaction processing system without locking the pages are disclosed. The system maintains a Global-- Committed-- LSN identifying the oldest uncommitted transaction accessing any of the data, and Object-- Committed-- LSNs identifying the oldest uncommitted transactions accessing particular files, tables and indexes. Each data page includes a Page-- LSN identifying the last transaction to have updated the page. To read a page, a transaction first latches the pages, and compares the page'"'"'s Page-- LSN with the Global-- Committed-- LSN, or with the page'"'"'s respective Object-- Committed-- LSN. If the Page-- LSN is older than the Committed-- LSN with which it was compared, then the transaction reads the page without locking it, since there can be no uncommitted transaction in process which might have updated the page'"'"'s data. However if the Page-- LSN is younger than the Committed-- LSN, the page is locked before being read.
-
Citations
16 Claims
-
1. In a computerized data processing system having a plurality of data units, each data unit being identified by a respective first identifier which reflects an age not older than the age of the youngest modification of the data unit, a method of accessing a selected one of the data units by a selected one of a plurality of processes comprising the steps performed by the data processing system of:
-
(a) maintaining a second identifier which reflects an age at least as old as the then-oldest in-process modification of a first plurality of the plurality of data units; (b) comparing the second identifier with the selected data unit'"'"'s respective first identifier; (c) obtaining access to the data unit for the selected process compatibly with other process'"'"' accesses to the data unit, said step of obtaining access being performed using fewer computer instructions if the selected data unit'"'"'s respective first identifier is older than the second identifier than if the selected data unit'"'"'s respective first identifier is not older than the second identifier; and (d) reading the data unit by the selected process. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8)
-
-
9. A data processing system comprising:
-
a plurality of data units, each data unit being identified by a first respective identifier means which reflects an age not older than the age of the youngest modification of the data unit; means for reading a selected one of the plurality of data units to which access has been obtained; means for maintaining a second identifier which reflects an age at least as old as the then-oldest in-process modification of a first plurality of the plurality of data units; means for comparing the second identifier with the selected data unit'"'"'s respective first identifier means; and means for obtaining access to the selected data unit for the selected process compatibly with other process'"'"' accesses to the selected data unit, said access obtaining means comprising fewer computer instruct if the selected data unit'"'"'s respective first identifier is older than the second identifier than if the selected data unit'"'"'s respective first identifier is not older than the second identifier. - View Dependent Claims (10, 15, 16)
-
-
11. A method for accessing a selected one of a plurality of data units, maintained on a data processing system, by a selected one of a plurality of processes, the method comprising the steps of:
-
maintaining, for each respective one of the plurality of data units, a first identifier which identifies a most recent time at which the respective data unit was modified; maintaining a second identifier which identifies a time of commencement of an oldest in-progress modification of any one of a first plurality of the plurality of data units, the first plurality of data units including the selected one of the plurality of data units; comparing the second identifier with the first identifier of the selected one of the plurality of data units to determine whether the most recent modification of the selected data unit occurred prior to the commencement of the oldest in-progress modification of any one of the first plurality of data units; accessing the selected one of the plurality of data units according to a first set of computer instructions if the step of comparing determines that the most recent modification of the selected data unit occurred prior to the commencement of the oldest in-progress modification of any one of the first plurality of data units; and accessing the selected one of the plurality of data units according to a second set of computer instructions otherwise. - View Dependent Claims (12, 13, 14)
-
Specification