write

fun write(batch: WriteBatch)

Commits batch as one record. An empty batch does nothing.

Single-key put and delete go through this same path rather than a fast path of their own, so there is exactly one place where the order of log first, memtable second is decided. That order is the guarantee: a memtable holding an entry the log does not is the one arrangement that can survive a crash as an unacknowledged write that is nevertheless present.