Saltar al contenido
← volver

Why Two Tabs Silently Overwrote Each Other: Field Notes on Lost Updates, Version Columns, and ETags

DEV · dev.to Publicado:

Headline: A lost update happens when two clients read the same record, both edit it, and the second save silently overwrites the first. Database transactions do not prevent it when the read and the write happen in separate HTTP requests; optimistic concurrency control does — an integer version column checked in the UPDATE's WHERE clause, exposed to HTTP clients as an ETag and If-Match header, and shown to the user as an explicit conflict instead of silent data loss. I found this one while testi…

Leer original →

Más de DEV