News for hackers. Stuff that matters.
Re:It’s Time to Move on from Two Phase Commit by samrift on Friday January 25, 2019 @01:09PM (#19000584)
Indeed.

Don't forget that you now have to come up with a distrbuted atomicity protocol that avoids deadlocks. That's a lot of handwaving.

Re:It’s Time to Move on from Two Phase Commit by abadid on Friday January 25, 2019 @01:18PM (#19000676)
It would be hand-waving if we didn't actually do it :)

Calvin uses a locking scheme with deadlock avoidance. PVW uses a MVCC scheme with no locking (and therefore no deadlock). Fauna uses an OCC scheme with no deadlock and deterministic validation.

Re:It’s Time to Move on from Two Phase Commit by samrift on Friday January 25, 2019 @01:31PM (#19000842)
Not trying to say you can't do it - I'm sure I'm just not informed enough.

However, I don't see how MVCC could fix a multi-worker issue that would cause category (1) aborts in your scenario.

With MVCC, if another worker concurrently modifies a record ( say 'Y'), I continue to read the pre-modified value once I've read it. So my value for Y may be incorrect between the time I check it's greater than 0, and the time I set X to 42. My constraint check was invalid.

At this point you either have a transaction that can't commit despite your guarantee it can (because my conditional passed!) , or an 'eventual consistency' model where the consistency will be reconciled outside the scope of original change (and in this model you wouldn't use 2PC anyway).

Re:It’s Time to Move on from Two Phase Commit by abadid on Friday January 25, 2019 @03:01PM (#19001927)
The assumption is that the data partitions are disjoint. Each worker controls its own data and therefore controls what value the other workers see. So the worker is responsible for making sure the other workers read the correct version.
Re:It’s Time to Move on from Two Phase Commit by angry_octet on Friday January 25, 2019 @07:55PM (#19003991)
How can it possibly know which is the correct version if it doesn't know what other workers have processed?
Re:It’s Time to Move on from Two Phase Commit by magicalhippo on Saturday January 26, 2019 @06:42AM (#19005904)
My assumption reading the article was that each transaction is assigned a unique id. Then a worker could ask another worker for "y for/as of transaction 42".

Maybe I'm all wrong tho.

Re:It’s Time to Move on from Two Phase Commit by abadid on Saturday January 26, 2019 @08:36PM (#19009858)
What you say is correct :)