flush

fun flush(file: String)

Flushes the RAM buffer to storage safely. Will create writer lazily (if they cant do it, then they will abort instead of shutting down) and handle errors.