-
Notifications
You must be signed in to change notification settings - Fork 4.1k
*: Remove SNAPSHOT isolation #26475
Description
Our implementation of SNAPSHOT isolation is buggy (#23176, #26460) and under-tested. Since the introduction of RefreshSpans in 2.0, it doesn't even improve performance significantly in most cases. We have discouraged its use by mapping all four ANSI isolation levels to SERIALIZABLE, so users wouldn't get SNAPSHOT unless they specifically requested it. We should go the rest of the way and remove it completely.
We could remove the WriteTooOld and RetryOnPush fields of Transaction when SNAPSHOT isolation is gone. I think we might also be able to eliminate the distinction between the read and write timestamp cache.
In 2.1, we should map the SQL SNAPSHOT isolation level to SERIALIZABLE, but we'll need to leave all the supporting machinery in place until 2.2.