November 2018
Beginner to intermediate
260 pages
6h 12m
English
Ignite keeps track of the 'last access' timestamp of all pages in an array. When a page is accessed, the array entry is updated with the timestamp. The random LRU algorithm randomly finds five pages from the array and evicts the oldest timestamp page.
The following Java configuration sets the random LRU eviction algorithm for a data region:
DataRegionConfiguration region1= new DataRegionConfiguration(); region1.setName("region1"); region1.setPageEvictionMode(DataPageEvictionMode.RANDOM_LRU);
The corresponding XML configuration is as follows:
<bean class="org.apache.ignite.configuration.DataRegionConfiguration"> <property name="pageEvictionMode" value="RANDOM_LRU"/>
Read now
Unlock full access