MAINTAINING CROSS-NODE COHERENCE OF AN IN-MEMORY DATABASE OBJECT IN A MULTI-NODE DATABASE CLUSTER
First Claim
1. A method comprising:
- maintaining, in a persistent storage, a database that is accessible to a plurality of database server instances;
wherein the database includes a table that is physically organized in a plurality of units, wherein each unit of the plurality of units is stored in persistent storage and comprises one or more contiguous rows of the table stored in row-major format;
generating, in a first volatile memory local to a first database server instance of the plurality of database server instances, a first in-memory copy of a first chunk of the table;
wherein the first in-memory copy of the first chunk of the table comprises one or more columns from one or more units of the plurality of units in column-major format;
acquiring, by the first database server instance, a first lock that covers a particular unit of the plurality of units;
receiving, at the first database server instance, a first request to release the first lock;
in response to receiving the first request, releasing the first lock, andin response to releasing the first lock, storing, in the first volatile memory, a first indication that each row in the first in-memory copy of the first chunk that is also generated from the particular unit is invalid;
wherein the first database server instance responds to requests to read data from the first chunk by;
obtaining data items, that belong to the first chunk and that have not been invalidated in the first in-memory copy, from the first in-memory copy; and
obtaining data items, that belong to the first chunk and have been invalidated in the first in-memory copy, from a source other than the first in-memory copy;
wherein the method is performed by one or more computing devices.
1 Assignment
0 Petitions
Accused Products
Abstract
Techniques are described for maintaining coherency of a portion of a database object populated in the volatile memories of multiple nodes in a database cluster. The techniques involve maintaining a local invalidation bitmap for chunks of data stored in memory in each particular node in the cluster by tracking locks granted by a lock manager. During a pre-loading operation, each given node requests a set of shared locks associated with the chunks of data to be store in the given node'"'"'s memory. When a request to release one of these shared locks occurs, the in-memory copy of those data items may be invalidated in the node releasing its shared lock.
-
Citations
22 Claims
-
1. A method comprising:
-
maintaining, in a persistent storage, a database that is accessible to a plurality of database server instances; wherein the database includes a table that is physically organized in a plurality of units, wherein each unit of the plurality of units is stored in persistent storage and comprises one or more contiguous rows of the table stored in row-major format; generating, in a first volatile memory local to a first database server instance of the plurality of database server instances, a first in-memory copy of a first chunk of the table; wherein the first in-memory copy of the first chunk of the table comprises one or more columns from one or more units of the plurality of units in column-major format; acquiring, by the first database server instance, a first lock that covers a particular unit of the plurality of units; receiving, at the first database server instance, a first request to release the first lock; in response to receiving the first request, releasing the first lock, and in response to releasing the first lock, storing, in the first volatile memory, a first indication that each row in the first in-memory copy of the first chunk that is also generated from the particular unit is invalid; wherein the first database server instance responds to requests to read data from the first chunk by; obtaining data items, that belong to the first chunk and that have not been invalidated in the first in-memory copy, from the first in-memory copy; and obtaining data items, that belong to the first chunk and have been invalidated in the first in-memory copy, from a source other than the first in-memory copy; wherein the method is performed by one or more computing devices. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11)
-
-
12. One or more non-transitory computer-readable media storing instructions, wherein the instructions include:
-
instructions which, when executed by one or more hardware processors, cause maintaining, in a persistent storage, a database that is accessible to a plurality of database server instances; wherein the database includes a table that is physically organized in a plurality of units, wherein each unit of the plurality of units is stored in persistent storage and comprises one or more contiguous rows of the table stored in row-major format; instructions which, when executed by the one or more hardware processors, cause generating, in a first volatile memory local to a first database server instance of the plurality of database server instances, a first in-memory copy of a first chunk of the table; wherein the first in-memory copy of the first chunk of the table comprises one or more columns from one or more units of the plurality of units in column-major format; instructions which, when executed by the one or more hardware processors, cause acquiring, by the first database server instance, a first lock that covers a particular unit of the plurality of units; instructions which, when executed by the one or more hardware processors, cause receiving, at the first database server instance, a first request to release the first lock; instructions which, when executed by the one or more hardware processors, cause, in response to receiving the first request, releasing the first lock, and instructions which, when executed by the one or more hardware processors, cause, in response to releasing the first lock, storing, in the first volatile memory, a first indication that each row in the first in-memory copy of the first chunk that is also generated from the particular unit is invalid; wherein the first database server instance responds to requests to read data from the first chunk by; obtaining data items, that belong to the first chunk and that have not been invalidated in the first in-memory copy, from the first in-memory copy; and obtaining data items, that belong to the first chunk and have been invalidated in the first in-memory copy, from a source other than the first in-memory copy. - View Dependent Claims (13, 14, 15, 16, 17, 18, 19, 20, 21, 22)
-
Specification