Pessimistic Locking
Lock a set of rows in the database, typically using FOR UPDATE and make it isolation so that a request needs to wait until other request is done.
Which further on can extend to Two Phase Commit or Saga architecture pattern
Lock a set of rows in the database, typically using FOR UPDATE and make it isolation so that a request needs to wait until other request is done.
Which further on can extend to Two Phase Commit or Saga architecture pattern