FlushPolicy

abstract class FlushPolicy

FlushPolicy controls when segments are flushed from a RAM resident internal data-structure to the IndexWriters Directory.

Segments are traditionally flushed by:

IndexWriter consults the provided FlushPolicy to control the flushing process. The policy is informed for each added or updated document as well as for each delete term. Based on the FlushPolicy, the information provided via DocumentsWriterPerThread and DocumentsWriterFlushControl, the FlushPolicy decides if a [ ] needs flushing and mark it as flush-pending via , or if deletes need to be applied.

See also

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
fun init(indexWriterConfig: LiveIndexWriterConfig)

Called by DocumentsWriter to initialize the FlushPolicy

Link copied to clipboard

Called for each delete, insert or update. For pure deletes, the given [ ] may be null.