News for hackers. Stuff that matters.
Re:Your ATM does not use transactions by jacques_chester on Thursday January 10, 2013 @09:49AM (#5037084)
> you can log your credits and debits in different accounts, no need for ACID transactions here,

Um, yes. There is. There totally is.

There's a reason ACID is illustrated with examples based on debiting one account and crediting another at what is a logically simultaneous instance (Atomicity).

Because if you do one and not the other, your accounts are now Wrong-with-a-capital-W-for-legal-consequences (Consistency).

We need these to happen in some sort of order, so we pretend only one such entry happens at a time (Isolation).

It would also be jolly nice if we didn't lose the records (Durability) every time the RAM lost its juice.

> You don't require from your data to be consistent at every instant

Again: yes. You do. That's literally the entire purpose of double-entry bookkeeping: to guarantee that the books are always consistent.

There are no comments on this comment yet.