Modifier and Type | Field and Description |
---|---|
protected EvictionChecker |
evictionChecker |
protected MapServiceContext |
mapServiceContext |
protected static int |
ONE_HUNDRED_PERCENT |
Constructor and Description |
---|
EvictorImpl(EvictionChecker evictionChecker,
MapServiceContext mapServiceContext) |
Modifier and Type | Method and Description |
---|---|
protected long[] |
createAndPopulateEvictionCriteriaArray(RecordStore recordStore,
EvictionPolicy evictionPolicy) |
int |
findRemovalSize(RecordStore recordStore)
Find size to evict from a record-store.
|
EvictionChecker |
getEvictionChecker()
Get eviction checker for this
Evictor |
protected long |
getEvictionCriteriaValue(Record record,
EvictionPolicy evictionPolicy) |
protected int |
getEvictionStartIndex(long[] criterias,
int evictableSize) |
protected boolean |
isBackup(RecordStore recordStore) |
void |
removeSize(int removalSize,
RecordStore recordStore)
Remove supplied number of elements from record-store.
|
protected boolean |
tryEvict(Data key,
Record record,
RecordStore recordStore,
boolean backup,
long now) |
protected static final int ONE_HUNDRED_PERCENT
protected final MapServiceContext mapServiceContext
protected final EvictionChecker evictionChecker
public EvictorImpl(EvictionChecker evictionChecker, MapServiceContext mapServiceContext)
public EvictionChecker getEvictionChecker()
Evictor
Evictor
getEvictionChecker
in interface Evictor
EvictionChecker
public void removeSize(int removalSize, RecordStore recordStore)
Evictor
removeSize
in interface Evictor
removalSize
- supplied size to remove.recordStore
- the recordStoreprotected boolean isBackup(RecordStore recordStore)
protected boolean tryEvict(Data key, Record record, RecordStore recordStore, boolean backup, long now)
protected long[] createAndPopulateEvictionCriteriaArray(RecordStore recordStore, EvictionPolicy evictionPolicy)
protected int getEvictionStartIndex(long[] criterias, int evictableSize)
public int findRemovalSize(RecordStore recordStore)
Evictor
findRemovalSize
in interface Evictor
recordStore
- the recordStoreprotected long getEvictionCriteriaValue(Record record, EvictionPolicy evictionPolicy)
Copyright © 2016 Hazelcast, Inc.. All Rights Reserved.