Skip to content
Snippets Groups Projects
Commit 9d14011f authored by Konstantin Osipov's avatar Konstantin Osipov
Browse files
A fix for bug https://bugs.launchpad.net/tarantool/+bug/790688
"ER_TUPLE_IS_RO should be more rare".

Rewrite the transaction processor to optimistically
perform changes in memory. In case of an error, transactions
are rolled back in order, reverse to the order of execution,
and gradually restore the original state of memory.
The wal writer therad orchestrates the rollback, by not
initiating it until all queries which entered the processing queue
before the error has occurred were not added to the rollback queue.

While in the state of rollback (i.e. collecting all requests
for rollback) new requests are not accepted into the processing
queue (see changes in wal_write()).

XXX: This patch makes dirty reads possible when we are in rollback,
since SELECTs do not enter the wal writer queue and can therefore
see changes which later will be rolled back. Since this is a
very rare situation, it's considered acceptable to fix this problem
in a separate patch (a separate bug will be reported).
parent b620082e
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment