|
IBM WebSphere® DataPower® XC10 Appliance Release 1.0 Client API Specification |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Evictor
Data contained in a BackingMap
are evicted when the map is
full. This plugin is used by the BackingMap
to determine when
and what to evict from the map based on some algorithm (LRU, LFU, time
based, etc).
BackingMap.setEvictor(Evictor)
,
EvictorData
Method Summary | |
---|---|
void |
activate()
This method is called to activate the Evictor. |
void |
apply(LogSequence sequence)
Called after a transaction has committed to allow the evictor to track object usage in the BackingMap . |
void |
deactivate()
This method is called to deactivate the Evictor. |
void |
destroy()
Called when the BackingMap associated with this evictor is
destroyed. |
void |
initialize(BackingMap map,
EvictionEventCallback callback)
Called by a BackingMap instance during the evictor
initialization time. |
Method Detail |
---|
void initialize(BackingMap map, EvictionEventCallback callback)
Called by a BackingMap
instance during the evictor
initialization time.
The BackingMap
calls this method so the Evictor
instance can have references to the BackingMap
and
EvictionEventCallback
instances. The evictor can signal
events to have specific entries evicted using the
EvictionEventCallback
.
map
- the BackingMap instancecallback
- the EvictionEventCallback instanceBackingMap
,
EvictionEventCallback
void destroy()
Called when the BackingMap
associated with this evictor is
destroyed.
This method is the opposite of the initialize
method. When
it is called, the Evictor can free up any resources it uses.
ObjectGrid.destroy()
void apply(LogSequence sequence)
BackingMap
.
This method also reports any entries that have been successfully evicted.
Note, this method is not called for transactions that are rolled back. If
there is a need to track object usage for rolled back transactions, the
evictor must implement the RollbackEvictor
interface as
well.
This method is called after a transaction has completed. Consequently, all transaction locks that were acquired by the completed transaction are no longer held. Potentially, multiple threads could call this method concurrently and each thread would be completing its own transaction. Since transaction locks are already released by the completed transaction, this method must provide its own synchronization to ensure it is thread safe.
sequence
- the LogSequence
of changes committed to the mapRollbackEvictor
void activate()
void deactivate()
|
IBM WebSphere® DataPower® XC10 Appliance Release 1.0 Client API Specification |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |