pub trait Warmer: Sync + Send {
    fn warm(&self, searcher: &Searcher) -> Result<()>;
    fn garbage_collect(&self, live_generations: &[&SearcherGeneration]);
}
Expand description

Warmer can be used to maintain segment-level state e.g. caches.

They must be registered with the IndexReaderBuilder.

Required Methods

Perform any warming work using the provided Searcher.

Discards internal state for any SearcherGeneration not provided.

Implementors