flush

fun flush()

Moves all in-memory segments to the Directory, but does not commit (fsync) them (call .commit for that).


fun flush(triggerMerge: Boolean, applyAllDeletes: Boolean)

Flush all in-memory buffered updates (adds and deletes) to the Directory.

Parameters

triggerMerge

if true, we may merge segments (if deletes or docs were flushed) if necessary

applyAllDeletes

whether pending deletes should also