public class IndicesFieldDataCacheListener extends Object implements IndexFieldDataCache.Listener
IndexFieldDataCache.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 the CircuitBreakerService
.Constructor and Description |
---|
IndicesFieldDataCacheListener(CircuitBreakerService circuitBreakerService) |
Modifier and Type | Method and Description |
---|---|
void |
onCache(ShardId shardId,
MappedFieldType.Names fieldNames,
FieldDataType fieldDataType,
org.apache.lucene.util.Accountable fieldData)
Called after the fielddata is loaded during the cache phase
|
void |
onRemoval(ShardId shardId,
MappedFieldType.Names fieldNames,
FieldDataType fieldDataType,
boolean wasEvicted,
long sizeInBytes)
Called after the fielddata is unloaded
|
@Inject public IndicesFieldDataCacheListener(CircuitBreakerService circuitBreakerService)
public void onCache(ShardId shardId, MappedFieldType.Names fieldNames, FieldDataType fieldDataType, org.apache.lucene.util.Accountable fieldData)
IndexFieldDataCache.Listener
onCache
in interface IndexFieldDataCache.Listener
public void onRemoval(ShardId shardId, MappedFieldType.Names fieldNames, FieldDataType fieldDataType, boolean wasEvicted, long sizeInBytes)
IndexFieldDataCache.Listener
onRemoval
in interface IndexFieldDataCache.Listener
Copyright © 2009–2016. All rights reserved.