cockroachdb/cockroach — pull request #74 by spencerkimball (2014-09-22 14:01:16+00:00)
Title: Always read writes from same txn epoch.

We must do this even in the event that the timestamp of a write from our
own txn gets pushed forward so txn is attempting to read earlier
timestamp. We can't have a txn intent getting pushed forward by another
txn only to have it become invisible to the current txn, which isn't yet
aware the txn commit timestamp has been pushed.

Allow non-transactional reads and writes to push intents. This is
done by generating a random priority for the non-transactional actor.
We could consider allowing priority to be set as an optional field of
RequestHeader, outside of RequestHeader.Txn for non-transactional commands.

Change push txn code to always allow pushing the timestamp forward on
txn intents where isolation level is SNAPSHOT. Since snapshot isolation
txns don't mind having their timestamp advanced, this is better overall
for system performance--readers never block on snapshot isolation txns.

Added unittests for all cases.