Class IndicesFieldDataCacheListener
- java.lang.Object
-
- org.elasticsearch.indices.fielddata.cache.IndicesFieldDataCacheListener
-
- All Implemented Interfaces:
IndexFieldDataCache.Listener
public class IndicesFieldDataCacheListener extends java.lang.Object implements IndexFieldDataCache.Listener
AIndexFieldDataCache.Listener
implementation that updates indices (node) level statistics / service about field data entries being loaded and unloaded. Currently it only decrements the memory used in theCircuitBreakerService
.
-
-
Constructor Summary
Constructors Constructor Description IndicesFieldDataCacheListener(CircuitBreakerService circuitBreakerService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
onCache(ShardId shardId, java.lang.String fieldName, org.apache.lucene.util.Accountable fieldData)
Called after the fielddata is loaded during the cache phasevoid
onRemoval(ShardId shardId, java.lang.String fieldName, boolean wasEvicted, long sizeInBytes)
Called after the fielddata is unloaded
-
-
-
Constructor Detail
-
IndicesFieldDataCacheListener
@Inject public IndicesFieldDataCacheListener(CircuitBreakerService circuitBreakerService)
-
-
Method Detail
-
onCache
public void onCache(ShardId shardId, java.lang.String fieldName, org.apache.lucene.util.Accountable fieldData)
Description copied from interface:IndexFieldDataCache.Listener
Called after the fielddata is loaded during the cache phase- Specified by:
onCache
in interfaceIndexFieldDataCache.Listener
-
onRemoval
public void onRemoval(ShardId shardId, java.lang.String fieldName, boolean wasEvicted, long sizeInBytes)
Description copied from interface:IndexFieldDataCache.Listener
Called after the fielddata is unloaded- Specified by:
onRemoval
in interfaceIndexFieldDataCache.Listener
-
-