Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
flush_job: do not roll back memtable flush on CF drop and DB shutdown (…
…#126) Rolling back in these cases is meaningless because the memtables will be freed shortly afterwards, so making them available for flush again is useless at best. Additionally, in atomic flush, memtables that were successfully flushed aren't rolled back if a CF is dropped or a DB shutdown was requested (the shutdown case is the more relevant one for the comparison here because it aborts the flush, whereas the in the CF drop case it's simply ignored at flush result installation time). In this regard this change simply matches the behaviour there. Lastly, this might be needed for the WriteBufferManager changes in #113, since we plan to use the information about memory that can be flushed in the future for triggering flushes based on immutable memory as well, and rolling back flushes causes the memtable memory to become ready for flush again for a brief period of time until it is dropped, which might wrongly affect the WBM decisions.
- Loading branch information