#engineering #pattern


Concurrency control is an abstract mechanism helping to handle multiple concurrent requests, and provide a deterministic result. They can be optimistic: assume that requests won't interfere with each other and allow concurrency but use detection mechanisms to rollback conflicts, such as Etags[1], version ids, or timestamps ; or pessimistic: assume that requests will conflict and therefore put up locks to prevent.



[1]: Wikipedia / Etags