Distributed consistent grid of in-memory database caches
First Claim
1. A method comprising:
- maintaining a grid of mid-tier databases storing cache instances of elements from one or more backend data sources, wherein changes to said cache instances are propagated back to the one or more backend data sources;
receiving requests to change data in a particular mid-tier database, said data belonging to particular elements in the one or more backend data sources;
in response to each particular request of the requests;
identifying a particular cache instance mapped to particular data indicated by the particular request;
determining ownership information for the particular cache instance, wherein the ownership information indicates either;
a) a mid-tier database to which the particular cache instance has been exclusively assigned, or b) that the particular cache instance is not yet stored in the grid; and
waiting to change the particular data in the particular mid-tier database at least until the ownership information indicates that the particular database has exclusive ownership of the particular cache instance;
wherein, for at least some particular requests of the requests, the ownership information is updated to indicate that the particular mid-tier database has been assigned exclusive ownership upon at least;
determining that another mid-tier database in the grid stores the particular cache instance;
causing any pending transactions relating to the particular cache instance at the other mid-tier database to be committed;
transmitting the particular cache instance from the other mid-tier database to the particular mid-tier database;
wherein the method is performed by one or more computing devices implementing the grid.
1 Assignment
0 Petitions
Accused Products
Abstract
A plurality of mid-tier databases form a single, consistent cache grid for data in a one or more backend data sources, such as a database system. The mid-tier databases may be standard relational databases. Cache agents at each mid-tier database swap in data from the backend database as needed. Consistency in the cache grid is maintained by ownership locks. Cache agents prevent database operations that will modify cached data in a mid-tier database unless and until ownership of the cached data can be acquired for the mid-tier database. Cache groups define what backend data may be cached, as well as a general structure in which the backend data is to be cached. Metadata for cache groups is shared to ensure that data is cached in the same form throughout the entire grid. Ownership of cached data can then be tracked through a mapping of cached instances of data to particular mid-tier databases.
46 Citations
31 Claims
-
1. A method comprising:
-
maintaining a grid of mid-tier databases storing cache instances of elements from one or more backend data sources, wherein changes to said cache instances are propagated back to the one or more backend data sources; receiving requests to change data in a particular mid-tier database, said data belonging to particular elements in the one or more backend data sources; in response to each particular request of the requests; identifying a particular cache instance mapped to particular data indicated by the particular request; determining ownership information for the particular cache instance, wherein the ownership information indicates either;
a) a mid-tier database to which the particular cache instance has been exclusively assigned, or b) that the particular cache instance is not yet stored in the grid; andwaiting to change the particular data in the particular mid-tier database at least until the ownership information indicates that the particular database has exclusive ownership of the particular cache instance; wherein, for at least some particular requests of the requests, the ownership information is updated to indicate that the particular mid-tier database has been assigned exclusive ownership upon at least; determining that another mid-tier database in the grid stores the particular cache instance; causing any pending transactions relating to the particular cache instance at the other mid-tier database to be committed; transmitting the particular cache instance from the other mid-tier database to the particular mid-tier database; wherein the method is performed by one or more computing devices implementing the grid. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13)
-
-
14. A method comprising:
-
maintaining a grid of mid-tier databases storing cache instances of elements from one or more one or more backend data sources, wherein changes to said cache instances are propagated back to the one or more backend data sources; receiving a request to change data in a particular mid-tier database, said data belonging to a particular element in the one or more backend data sources; in response to the request; determining whether the particular mid-tier database stores a particular cache instance corresponding to the particular element; responsive to determining that the particular mid-tier database stores the particular cache instance corresponding to the particular element; determining that the particular mid-tier database has been assigned exclusive ownership of the particular cache instance; responsive to determining that the particular mid-tier database does not store the particular cache instance corresponding to the particular element; determining whether any other mid-tier database in the grid stores the particular cache instance corresponding to the particular element; responsive to determining that an other mid-tier database stores the particular cache instance corresponding to the particular element; causing any pending transactions relating to the particular cache instance at the other mid-tier database to be committed; moving the particular cache instance from the other mid-tier database to the particular mid-tier database; responsive to determining that no other mid-tier database stores the particular cache instance corresponding to the particular element; generating the particular cache instance for the particular element; storing the particular cache instance at the particular mid-tier database; upon storing the particular cache instance at the particular mid-tier database, determining that the particular mid-tier database has been assigned exclusive ownership of the particular cache instance; changing the data in the particular mid-tier database upon determining that the particular database has been assigned exclusive ownership of the particular cache instance; wherein the method is performed by one or more computing devices implementing the grid.
-
-
15. A system comprising:
-
one or more backend data sources stored in at least one persistent storage device; a backend server executing at a first set of one or more computing devices, the backend server being configured to provide access to the one or more backend data sources; a plurality of mid-tier databases stored at a second set of one or more computing devices; one or more processes executing at the second set of computing devices, the one or more processes configured to maintain, in the plurality of mid-tier databases, a caching grid, said caching grid comprising at least a plurality of shared cache instances of data from the one or more backend data sources; wherein the plurality of shared cache instances are stored in the plurality of mid-tier databases; wherein the one or more processes ensure that for any given data element of the one or more backend data sources for which the caching grid maintains a shared cache instance, the plurality of mid-tier databases store, at any given time, no more than one version of the shared cache instance; wherein the second set of one or more computing devices are configured to; receive requests to change data in a particular mid-tier database, said data belonging to particular elements in the one or more backend data sources; in response to each particular request of the requests; identify a particular cache instance mapped to particular data indicated by the particular request; determine ownership information for the particular cache instance, wherein the ownership information indicates either;
a) a mid-tier database to which the particular cache instance has been exclusively assigned, or b) that the particular cache instance is not yet stored in the grid; andwait to change the particular data in the particular mid-tier database at least until the ownership information indicates that the particular database has exclusive ownership of the particular cache instance; wherein, for at least some particular requests of the requests, the ownership information is updated to indicate that the particular mid-tier database has been assigned exclusive ownership upon at least; determining that another mid-tier database in the grid stores the particular cache instance; causing any pending transactions relating to the particular cache instance at the other mid-tier database to be committed; transmitting the particular cache instance from the other mid-tier database to the particular mid-tier database. - View Dependent Claims (16, 17)
-
-
18. One or more storage media storing instructions which, when executed by one or more computing devices, cause performance of:
-
maintaining a grid of mid-tier databases storing cache instances of elements from one or more backend data sources, wherein changes to said cache instances are propagated back to the one or more backend data sources; receiving requests to change data in a particular mid-tier database, said data belonging to particular elements in the one or more backend data sources; in response to each particular request of the requests; identifying a particular cache instance mapped to particular data indicated by the particular request; determining ownership information for the particular cache instance, wherein the ownership information indicates either;
a) a mid-tier database to which the particular cache instance has been exclusively assigned, or b) that the particular cache instance is not yet stored in the grid; andwaiting to change the particular data in the particular mid-tier database at least until the ownership information indicates that the particular database has exclusive ownership of the particular cache instance; wherein, for at least some particular requests of the requests, the ownership information is updated to indicate that the particular mid-tier database has been assigned exclusive ownership upon at least; determining that another mid-tier database in the grid stores the particular cache instance; causing any pending transactions relating to the particular cache instance at the other mid-tier database to be committed; transmitting the particular cache instance from the other mid-tier database to the particular mid-tier database. - View Dependent Claims (19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30)
-
-
31. One or more storage media storing instructions which, when executed by one or more computing devices, cause performance of:
-
maintaining a grid of mid-tier databases storing cache instances of elements from one or more one or more backend data sources, wherein changes to said cache instances are propagated back to the one or more backend data sources; receiving a request to change data in a particular mid-tier database, said data belonging to a particular element in the one or more backend data sources; in response to the request; determining whether the particular mid-tier database stores a particular cache instance corresponding to the particular element; responsive to determining that the particular mid-tier database stores the particular cache instance corresponding to the particular element; determining that the particular mid-tier database has been assigned exclusive ownership of the particular cache instance; responsive to determining that the particular mid-tier database does not store the particular cache instance corresponding to the particular element; determining whether any other mid-tier database in the grid stores the particular cache instance corresponding to the particular element; responsive to determining that an other mid-tier database stores the particular cache instance corresponding to the particular element; causing any pending transactions relating to the particular cache instance at the other mid-tier database to be committed; moving the particular cache instance from the other mid-tier database to the particular mid-tier database; responsive to determining that no other mid-tier database stores the particular cache instance corresponding to the particular element; generating the particular cache instance for the particular element; storing the particular cache instance at the particular mid-tier database; upon storing the particular cache instance at the particular mid-tier database, determining that the particular mid-tier database has been assigned exclusive ownership of the particular cache instance; changing the data in the particular mid-tier database upon determining that the particular database has been assigned exclusive ownership of the particular cache instance.
-
Specification