- Published on
Reference · Interrupted execution
Optimistic Locking With a Version Number
Two requests read the same row, both change it, and the second save quietly erases the first. A version number turns that silent bug into a conflict you can catch. Here is how optimistic locking works.