Efficient distributed lock manager
AssigneeOri Software Development Ltd.
InventorMoshe SHADMON
Life of this patent
Estimating the term…
Abstract
A system for managing a cluster of databases that process shared data, the system including a cluster of database nodes, each node including a memory, and a processor configured to, when it is determined that: (i) a lock on a resource is required by a particular node or process, and (ii) no other lock conflicts with this particular lock, send an asynchronous lock taken (ALT) message to a distributed lock manager (DLM); and without receiving a response or permission from the DLM, taking the lock for a resource for the particular node or process.
Claims18
A system for minimizing the number of requests required for locking a resource in a cluster of databases that process shared data, the system comprising:
- a cluster of one or more database nodes, each node of the cluster comprising:
- a memory;
- and
- a processor configured to:
- receive a user request to process one or more rows, the process configured to:
- (i) require a lock over the one or more rows being processed, and (ii) consider information included in a previous lock grant message for a lock over one or more blocks that maintain the one or more rows;
- determine the locking status of the one or more rows based on information included in the previous lock grant message;
- and
- for each such row, when the locking status of the row is determined to be not conflicting with a required locking status, lock the row by sending an asynchronous lock taken (ALT) message to a distributed lock manager (DLM) without needing to receive a response or permission from the DLM, the ALT message changing the locking status of the one or more rows to the required locking status.
A system for managing a cluster of databases that process shared data, the system comprising:
- a cluster of database nodes, each node comprising:
- a memory;
- and
- a processor configured to:
- when it is determined that:
- (i) a lock on a resource is required by a particular node or process, and (ii) no other lock conflicts with this particular lock, send an asynchronous lock taken (ALT) message to a distributed lock manager (DLM);
- and
- without receiving a response or permission from the DLM, taking the lock for a resource for the particular node or process.
A method for increasing locking efficiency in a cluster of database nodes that are synchronized by a distributed lock manager (DLM), the method comprising:
- determining that a process on a node of the cluster of database nodes requires a lock on a resource;
- determining that no other process on a different node maintains a lock on the resource;
- and
- granting an ownership mode to the node for the resource such that, while the node retains the ownership mode, no other process on a different node of the plurality of database nodes is granted a lock to the resource, and the local lock manager (LLM) of the node grants locking to the resource without needing to request the lock from the DLM.
A method for increasing locking efficiency in a cluster of database nodes that are synchronized by a distributed lock manager (DLM), the method comprising:
- determining that a node of the plurality of database nodes requires a read lock on a resource;
- determining that a read lock can be granted;
- granting a read-only mode to the node for the resource;
- while a node maintains a read-only mode, determining that a different node of the plurality of database nodes requires a read lock on the same resource;
- granting a read-only mode to the other node for the resource;
- such that, while a node retains the read-only mode, the processes on the node may read the resource without needing to request the lock from the DLM, and the processes on the node are not granted with a write lock.
A method of locking a resource by a distribute lock manager (DLM) that is initiated by a lock request from a node in a cluster of database nodes that are synchronized by a distributed lock manager (DLM), the method comprising:
- granting an ownership mode to a node for a resource such that, while the node retains the ownership mode, no other node of the cluster of database nodes is allowed to read or write to the resource, and a local lock manager (LLM) of the node grants locking to the resource without needing to request the lock from the DLM.
A method of locking, by a Distributed Lock Manager (DLM), being initiated by a lock request from a node in a cluster, the method comprising:
- locking the resource including granting a read-only mode to the node for the resource such that, while the node retains the read-only mode, the node may read the resource without having to request the lock from the DLM, and the node may not write to the resource, and other nodes requesting a read lock are granted with a read-only mode for the resource such that while a node retains the read-only mode, the node may read the resource without needing to request the lock from the DLM, and the node may not write to the resource.
A system for minimizing the number of requests required for locking in a cluster of database nodes, the system comprising:
- a cluster of one or more database nodes, each node of the cluster comprising:
- a memory;
- and
- a processor configured to:
- receive a user request to query, update, insert or delete data;
- send a request to a distributed lock manager (DLM) for a lock over one or more blocks that maintain the one or more rows;
- receive a lock grant message from the DLM, the lock grant message including information on the lock state of one or more rows contained in the one or more blocks;
- and
- when at least one of the one or more rows contained in the one or more blocks is not locked, taking a lock over the at least one of the one or more rows contained in the one or more blocks that are not locked by sending an asynchronous lock taken (ALT) message to the DLM without needing to receive a response or permission from the DLM relating the ALT message.
Dependencies are inferred from the claim text.