ACID and AWS DynamoDB transactions: The ins and outs of all-or-nothing
DynamoDB transactions allow cloud engineers to implement complicated business logic into a single atomic transaction.
Jun 08, 2023 • 3 Minute Read
A wise old man species of unknown origin once said, "Do. Or do not. There is no try." This sage advice rings true whether you’re trying to levitate a 12,000-pound X-Wing from a Dagobah swamp or writing all-or-nothing database-cloud transactions. Sometimes close doesn’t cut it. Take an online financial transaction. Let’s say you owe your friend for yesterday’s lunch. You open Venmo, find your friend, type in “10” for the $10 you want to send them, tack on a pizza emoji, and hit PAY. But then, weirdly enough, the notification you’re used to receiving seconds after that doesn’t appear. Something has gone wrong. So now what? Is your $10 lost in the electronic ether? Is your friend ever going to buy you lunch again? In this case, you don’t want anything to write or update unless all the parts of the pizza-payback operation are complete. For this, we can turn to AWS DynamoDB transactions.