Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
peapod: Do not commit idle batch transaction
Previously, Peapod collects write batch within 10ms and then flushes changes to physical drive. In the absence of operations during the lifetime of the current batch transaction, the latter was committed in any case and a new one was begun. This behavior could lead to idle commit-begin ops. Now each state-changing batch is marked. The flush cycle commits only non-idle batches: if current batch is idle, Peapod keeps related transaction for the time interval. When Peapod is closed, transaction related to idle batch is rolled back. Signed-off-by: Leonard Lyubich <[email protected]>
- Loading branch information