4 ms·
In databases, "locks" have a very specific meaning. What engineers would call a "lock", is referred to as a "latch" in DBMS internals terminology. A "lock" th
by gavinray 3y ago
In databases, "locks" have a very specific meaning.
What engineers would call a "lock", is referred to as a "latch" in DBMS internals terminology.
A "lock" then is a higher level abstraction that functions as a logical lock rather than a fine-grained physical one.
Locks are generally used to control access to database objects like rows, pages, tables, etc, to ensure data integrity and transactional consistency.
"Latches" are low-level synchronization primitives used to protect access to internal DB structures.