Shared read lock
From Wikipedia, the free encyclopedia
Information systems store structured information in a Database. A database is created, accessed, and manipulated via a Database management system (DBMS). DBMS theory and practice is an important subdicipline of computer science. Many databases are used to share data among a number of concurrent users. The classic example is an airline reservation system. When multiple users share a database, the DBMS must decide which user can make modifications at any given time. The basic approach it to create a lock when a user accesses data, and release the lock when the user is no longer accessing the data.
The simplest and most primitive form of lock is a database-level lock: Only one user at a time can access database. A database-level lock is unacceptable when many users must access the data concurrently as in an airplane reservation system, so more sophisticated locking protocols have been developed.
DBMSs have evolved since the inception of the computer age. Today, the prevalent model for database access is the relational model. In this model, the data is organized in "tables." Within each table, each set of data is a "row." There is a standard language, known as SQL, to access a relational database.
A shared read lock is a lock on the row and/or chunk of data that still allows the access of concurrent reads. The lock occurs in order to ensure that the read transaction is isolated from any changes that are going on during the read cycle.
Share read lock is usually a part of a read committed or repeatable read SQL isolation levels.