In this talk, I will look at how pessimistic, optimistic and no (explicit) locking works with relational databases and the best ways to use it from Django ORM
Most developers know a thing or two about multi-threading and concurrent programming. But the database often is treated as a black box not behaving as we expect it to and leading to weird bugs. We will look at concurrency in the database through programming language concepts and try to understand what happens behind the scenes of pessimistic and optimistic locking. We will discover how to use Django ORM and database locking and blocking to achieve correct, concurrent, and performant database updates.
Aivars Kalvāns is a FinTech developer, software architect, and consultant. He spent more than 18 years at Tieto developing and architecting payment card software for acquiring and issuing, accounting and utility payments through mobile phones, ATMs, and POS terminals. At the moment he is a contractor for Ebury exploring the Foreign Exchange area of the FinTech landscape.