Module org.elasticsearch.server
Class DelegatingBloomFilterFieldsProducer
java.lang.Object
org.apache.lucene.index.Fields
org.apache.lucene.codecs.FieldsProducer
org.elasticsearch.index.codec.bloomfilter.DelegatingBloomFilterFieldsProducer
- All Implemented Interfaces:
Closeable,AutoCloseable,Iterable<String>
public class DelegatingBloomFilterFieldsProducer
extends org.apache.lucene.codecs.FieldsProducer
A FieldsProducer that uses a Bloom filter for fast term existence checks before
delegating exact lookups to the underlying FieldsProducer. This avoids a potentially
expensive seek operations for non-existent terms.
-
Field Summary
Fields inherited from class org.apache.lucene.index.Fields
EMPTY_ARRAY -
Constructor Summary
ConstructorsConstructorDescriptionDelegatingBloomFilterFieldsProducer(org.apache.lucene.codecs.FieldsProducer delegate, BloomFilter bloomFilter) -
Method Summary
Methods inherited from class org.apache.lucene.codecs.FieldsProducer
getMergeInstanceMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
DelegatingBloomFilterFieldsProducer
public DelegatingBloomFilterFieldsProducer(org.apache.lucene.codecs.FieldsProducer delegate, BloomFilter bloomFilter)
-
-
Method Details
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein classorg.apache.lucene.codecs.FieldsProducer- Throws:
IOException
-
checkIntegrity
- Specified by:
checkIntegrityin classorg.apache.lucene.codecs.FieldsProducer- Throws:
IOException
-
iterator
-
terms
- Specified by:
termsin classorg.apache.lucene.index.Fields- Throws:
IOException
-
size
public int size()- Specified by:
sizein classorg.apache.lucene.index.Fields
-