re-implement transaction for sequential writes