Pessimistic Locking

Lock the database 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