Details
-
Improvement
-
Status: Open
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
-
Docs Required
Description
This is an idea that needs confirmation and accurate benchmarking.
Currently, when a read is performed inside an optimistic serializable transaction, we capture the value and entry version immediately regardless of the pending transactional locks for the read entry.
If there is a write candidate on the entry, this scenario will very likely result in optimistic write conflict exception. If a read observes a single (or several?) write candidates on the entry, we may stall the read until the pending prepared transaction is committed and proceed with the read only later. This is a speculative optimization, but it may reduce the chance of getting optimistic write conflict exception.