Class IndicesFieldDataCache
- java.lang.Object
-
- org.elasticsearch.indices.fielddata.cache.IndicesFieldDataCache
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
,RemovalListener<IndicesFieldDataCache.Key,org.apache.lucene.util.Accountable>
,Releasable
public class IndicesFieldDataCache extends java.lang.Object implements RemovalListener<IndicesFieldDataCache.Key,org.apache.lucene.util.Accountable>, Releasable
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
IndicesFieldDataCache.FieldDataWeigher
static class
IndicesFieldDataCache.Key
-
Field Summary
Fields Modifier and Type Field Description static Setting<ByteSizeValue>
INDICES_FIELDDATA_CACHE_SIZE_KEY
-
Constructor Summary
Constructors Constructor Description IndicesFieldDataCache(Settings settings, IndexFieldDataCache.Listener indicesFieldDataCacheListener)
-
Method Summary
Modifier and Type Method Description IndexFieldDataCache
buildIndexFieldDataCache(IndexFieldDataCache.Listener listener, Index index, java.lang.String fieldName)
void
close()
Cache<IndicesFieldDataCache.Key,org.apache.lucene.util.Accountable>
getCache()
void
onRemoval(RemovalNotification<IndicesFieldDataCache.Key,org.apache.lucene.util.Accountable> notification)
-
-
-
Field Detail
-
INDICES_FIELDDATA_CACHE_SIZE_KEY
public static final Setting<ByteSizeValue> INDICES_FIELDDATA_CACHE_SIZE_KEY
-
-
Constructor Detail
-
IndicesFieldDataCache
public IndicesFieldDataCache(Settings settings, IndexFieldDataCache.Listener indicesFieldDataCacheListener)
-
-
Method Detail
-
close
public void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfacejava.io.Closeable
- Specified by:
close
in interfaceReleasable
-
buildIndexFieldDataCache
public IndexFieldDataCache buildIndexFieldDataCache(IndexFieldDataCache.Listener listener, Index index, java.lang.String fieldName)
-
getCache
public Cache<IndicesFieldDataCache.Key,org.apache.lucene.util.Accountable> getCache()
-
onRemoval
public void onRemoval(RemovalNotification<IndicesFieldDataCache.Key,org.apache.lucene.util.Accountable> notification)
- Specified by:
onRemoval
in interfaceRemovalListener<IndicesFieldDataCache.Key,org.apache.lucene.util.Accountable>
-
-