Optimistic Locking - CI/CD Glossary Definition
Optimistic locking detects concurrent edits without holding a lock: each row carries a version, and an update only succeeds if the version still matches, otherwise the writer retries.
Versus pessimistic
Optimistic locking assumes conflicts are rare and pays nothing until one happens, where it fails the update and forces a retry. It scales better than holding locks when contention is low.
Related guides
Pessimistic Locking - CI/CD Glossary DefinitionPessimistic Locking: Pessimistic locking prevents conflicts by locking a row before reading or editing it (fo…
Transaction - CI/CD Glossary DefinitionTransaction: A transaction groups one or more statements into a single unit that either fully commits or full…