|Reported by:||dmisev||Owned by:||dmisev|
A simple transaction management for file blobs should be implemented.
Only once the SQLite RASBASE transaction is committed should changes to file blobs be permanently executed (like deletion or writing down).
This can be implemented with a simple queue of pending actions executed on transaction commit.
- inserts are immediately done to temporary blob files, and pending actions to move them to the real blob files are pushed to the queue
- rollback/abort removes the temporary files
- deletes are immediately done by moving real blob files to temporary ones, and pushing delete actions for the temporary blobs (opposite of inserts)
- rollback/abort moves the temporary files back to the real ones
Consistency should be tested by inserting segfaulting code at various points in the blob management code.