public class IndicesFieldDataCacheListener extends java.lang.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,
java.lang.String fieldName,
org.apache.lucene.util.Accountable fieldData)
Called after the fielddata is loaded during the cache phase
|
void |
onRemoval(ShardId shardId,
java.lang.String fieldName,
boolean wasEvicted,
long sizeInBytes)
Called after the fielddata is unloaded
|
@Inject public IndicesFieldDataCacheListener(CircuitBreakerService circuitBreakerService)
public void onCache(ShardId shardId, java.lang.String fieldName, org.apache.lucene.util.Accountable fieldData)
IndexFieldDataCache.ListeneronCache in interface IndexFieldDataCache.Listenerpublic void onRemoval(ShardId shardId, java.lang.String fieldName, boolean wasEvicted, long sizeInBytes)
IndexFieldDataCache.ListeneronRemoval in interface IndexFieldDataCache.Listener