ignite-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ivan Rakov <ivan.glu...@gmail.com>
Subject Re: IgfsPerBlockLruEvictionPolicy does not work as expected any more, what shall we do with it?
Date Wed, 24 May 2017 17:12:53 GMT
As for me, there's no reason to store IGFS blocks in cache with on-heap 
layer enabled.
I vote for the first option: deprecate/remove 
IgfsPerBlockLruEvictionPolicy (along with tests), recommend users to use 
page-based eviction if they need to evict blocks from primary IGFS.

Best Regards,
Ivan Rakov

On 24.05.2017 19:57, Ivan V. wrote:
> Hi, colleagues,
> as Ignite caches moved to paged offheap memory , the
> IgfsPerBlockLruEvictionPolicy does not seem to work as expected any more,
> because
> 1) interface org.apache.ignite.cache.eviction.EvictionPolicy now only
> defines "eviction from on-heap", not a real eviction, because each on-heap
> cache is now accompanied with underlying off-heap cache. It can become
> "real eviction" only for "on-heap-only" mode caches, once they get
>   implemented.
> 2) for off-heap eviction an entire page is evicted, not a specific k-v
> pair, and LRU policy is not exactly LRU any more (see
> org.apache.ignite.configuration.DataPageEvictionMode#RANDOM_LRU). So, it
> appears to be impossible to re-implement this policy for the off-heap layer.
> Thus, now IgfsPerBlockLruEvictionPolicy is not quite valid, and some of
> corresponding tests fail
> (org.apache.ignite.internal.processors.igfs.IgfsCachePerBlockLruEvictionPolicySelfTest#testDataSizeEviction,
>   org.apache.ignite.internal.processors.igfs.IgfsCachePerBlockLruEvictionPolicySelfTest#testBlockCountEviction)
> So, the options I see are:
> 1) deprecate/remove IgfsPerBlockLruEvictionPolicy ;
> 2) leave it as is, but explain in javadocs that it only works for on-heap
> layer, that does not in fact evict  blocks from the underlying offheap
> layer.
> Please share your opinions.

View raw message