The Importance of Being Transactional
  • Q: What is the importance of transactions?
  • A: They make it possible to build robust, reliable systems
  • Transactions preserve the ACID properties:
    • Atomic - Changes occur all or none
    • Consistent - System progresses from one consistent state to the next
    • Isolated - Activities within a transaction are not visible outside the transaction
    • Durable - The results of a committed transaction cannot be lost
  • From a programming point of view a transaction is like synchronized on steroids
    • synchronized provides isolation, but not the other properties
    • Transactions mean you don't need to worry about concurrency
    • Transactions mean you don't need to worry about crashes

Next Slide >>