Transactional protocol and system for implementing it
First Claim
1. Transactional protocol for data stored in a memory wherein, during a transaction including writing of a new value of at least one variable stored in a register of said memory, a read operation consists in, for each variable:
- allocating a read lock prohibiting writing to said transaction for said register;
then reading the content of said register;
and a write operation consists in, for each variable;
allocating a write intention lock to said transaction for said register prohibiting writing in said register by any transaction other than said transaction, but allowing reading;
associating a log register with said register and storing therein said new value of said variable;
and the closure of said transaction essentially consists in;
determining each register to which a write intention lock has been allocated for said transaction to be closed;
releasing any write lock allocated to said transaction to be closed;
then, for any register holding a write intention lock, for said transaction to be closed, verifying that there remains no read lock allocated to any other transaction for said register;
if at least one read lock remains for a time period exceeding a fixed limit, executing a procedure to abort said transaction to be closed;
or otherwise converting said write intention lock into a write lock;
then, for any register holding a write lock for said transaction to be closed;
transferring said new value of said variable from said log to said register;
and releasing said write lock allocated to said transaction to be closed for said register;
then sending a "transaction deemed completed" message to an application that requested closure of said transaction;
and said procedure for aborting said transaction to be closed consists in, for any register holding a write lock or write intention lock;
clearing the content of each log storing the value of a variable modified by the aborted transaction;
then releasing write locks and write intention locks allocated to said aborted transaction;
then sending a "transaction aborted" message to said application that requested closure of said transaction.
1 Assignment
0 Petitions
Accused Products
Abstract
A transactional protocol allocates write intention locks at the time of access to a transaction modifying data stored in a memory. These locks do not prohibit the allocation of read locks to other transactions. The other transactions can therefore read the old values of the variables until the new values are written into the memory when the transaction is closed. The time for which reading of data being modified is prohibited is restricted to the time to write the new values into the memory. This protocol is of particular benefit if the memory is a volatile memory and the modified data is backed up in another, non-volatile memory. In this case, the protocol further keeps up-to-date a table stored in the non-volatile memory and containing the identifiers of current transactions. This table is used to ensure that the data is consistent after failure of the volatile memory and contributes to maintaining a minimal time of prohibition of reading of data being modified. Applications of the protocol include telecommunication network control systems.
-
Citations
5 Claims
-
1. Transactional protocol for data stored in a memory wherein, during a transaction including writing of a new value of at least one variable stored in a register of said memory, a read operation consists in, for each variable:
-
allocating a read lock prohibiting writing to said transaction for said register; then reading the content of said register; and a write operation consists in, for each variable; allocating a write intention lock to said transaction for said register prohibiting writing in said register by any transaction other than said transaction, but allowing reading; associating a log register with said register and storing therein said new value of said variable; and the closure of said transaction essentially consists in; determining each register to which a write intention lock has been allocated for said transaction to be closed; releasing any write lock allocated to said transaction to be closed; then, for any register holding a write intention lock, for said transaction to be closed, verifying that there remains no read lock allocated to any other transaction for said register;
if at least one read lock remains for a time period exceeding a fixed limit, executing a procedure to abort said transaction to be closed;
or otherwise converting said write intention lock into a write lock;then, for any register holding a write lock for said transaction to be closed; transferring said new value of said variable from said log to said register; and releasing said write lock allocated to said transaction to be closed for said register; then sending a "transaction deemed completed" message to an application that requested closure of said transaction; and said procedure for aborting said transaction to be closed consists in, for any register holding a write lock or write intention lock; clearing the content of each log storing the value of a variable modified by the aborted transaction; then releasing write locks and write intention locks allocated to said aborted transaction; then sending a "transaction aborted" message to said application that requested closure of said transaction. - View Dependent Claims (4)
-
-
2. Transactional protocol for data stored identically in a non-volatile memory and in a volatile memory wherein, during a transaction including writing of a new value of at least one variable stored in a first register of said volatile memory and in a second register of said non-volatile memory,
a read operation consists in, for each variable: -
allocating a read lock prohibiting writing to said transaction for said first register, then reading the value of said register; and a write operation consists in, for each variable; allocating to said transaction, for said first register, a write intention lock prohibiting writing in said first register by any transaction other than said transaction to be closed, but allowing reading; associating with said first register a first log register and storing therein said new value of said variable; and said closure of said transaction essentially consists in; for any first register to which a write intention lock has been allocated by said transaction to be closed; determining the corresponding second register in said non-volatile memory; allocating to the second register thus determined a write lock for said transaction to be closed prohibiting reading and writing by any other transaction; associating with said second register thus determined a second log register and storing therein said new value of said variable; then writing the identifier of said transaction into a table of transactions stored in said non-volatile memory; releasing any read lock allocated to said transaction to be closed; then, for any first register holding a write intention lock, for said transaction to be closed, verifying that there remains no read lock allocated to any other transaction for said register, and, if at least one read lock remains during a time period exceeding a fixed limit, executing a procedure to abort said transaction to be closed; and
otherwise converting said write intention lock into a write lock;then, for any first register holding a write lock, for said transaction to be closed; transferring said new value of said variable from said log to said register; and releasing said write lock allocated to said transaction to be closed for said register; then sending a "transaction deemed completed" message to an application that requested closure of said transaction; then writing in said table an indicator associated with said identifier of said transaction and indicating that the latter is deemed completed; then, for any second register holding a write lock, for said transaction to be closed; transferring said new value of said variable from said second log to said second register; then releasing said write lock allocated to said transaction for said first register; and finally clearing said identifier of said transaction in said table; and the procedure for aborting said transaction to be closed consists in, for any first register; clearing the content of each first log holding the value of a variable modified by the aborted transaction; then releasing write intention locks and write locks allocated to said aborted transaction, for said first register; clearing the identifier of said aborted transaction in said table; then sending a "transaction aborted" message to said application that requested closure of said transaction; then clearing the content of each second log storing the value of a variable modified by said aborted transaction; then releasing write locks allocated to said aborted transaction for said second registers; and the procedure for restoring the content of said volatile memory after failure thereof consisting in; for any second register of said non-volatile memory, verifying if any write lock remains in said register, and; if no write lock remains therein, allocating a write lock to the first register corresponding to said second register, then transferring the content of said second register into said first register and releasing said write lock; if a write lock remains therein, determining if said lock belongs to a transaction the identifier of which is in said table of transactions; and
;if yes, transferring the content of said second log into said second register, then releasing said write lock, then allocating a write lock to the first register corresponding to said second register, then transferring the content of said second register into said first register, and releasing said write lock; if no, clearing the content of said second log and then releasing said write lock; finally, clearing all transaction identifiers in said table. - View Dependent Claims (3, 5)
-
Specification