More readwhilewriting tweaks from rocksdb