According to Pancho <Panc…@protonmail.com>:
>> Only up to a point. Making the read part of databases run in parallel >> is easy. Making the write part is not. >> >> If you have $100 in your bank account, and two $75 debit transactions >> arrive at the same time, if the result is anything other than that one >> succeeded and the other failed*, your bank has a problem. The reason they >> need very fast very large databases is that updates have to be serialized >> and there's no way to make them faster than the underlying system. Same >> for airlines allocating seats and any other database reflecting a real world >> application where there's a finite amount of something to be parcelled out. >> >> >> >> * - yes I know about overdrafts, this is an example
> >Erm, yep, sequential transactions on my account, but why does everyone >else's account need to be on the same database/compute server as my >account? If A and B are doing a transaction, that has nothing to do with >me, it can be done in parallel.
Sure, but you're not going to put every account on a different disk. Real transactions are more complicated than that -- when they take the $75 out of my account they have to credit it somewhere else, and that debit/credit pair has to be atomic, both work or both fail. Banks are conservative but they are not stupid. There's a lot of stuff they can push out onto cheap micro based servers, but there's a certain amount of key business logic that Absolutely Has To Work.
-- Regards, John Levine, joh…@taugh.com, Primary Perpetrator of "The Internet for Dummies", Please consider the environment before reading this e-mail. https://jl.ly