Here are the interesting points of the code. 

The other parts are not very relevant. 


private long offHeapMemoryMaxSize = 4 * 1024L * 1024L * 1024L;

    // Cache Configuration
    CacheConfiguration<K, V> cacheConf = new CacheConfiguration<K, V>();
    cacheConf.setName(cacheName);
    cacheConf.setEvictionPolicy(new FifoEvictionPolicy<>(1000));
    cacheConf.setOffHeapMaxMemory(offHeapMemoryMaxSize);
    cacheConf.setSwapEnabled(true);
    cacheConf.setMemoryMode(CacheMemoryMode.OFFHEAP_TIERED);
    cacheConf.setCacheMode(CacheMode.PARTITIONED);
    ...
    
    
    // Ignite configuration
    IgniteConfiguration conf = new IgniteConfiguration();
    conf.setGridName(name);    
    final FileSwapSpaceSpi fileSwapSpaceSpi = new FileSwapSpaceSpi();
    conf.setSwapSpaceSpi(fileSwapSpaceSpi);
    ...
    
    // cache data access
    cache.query(new ScanQuery<K,
V>().setPageSize(256).setLocal(true)).iterator();
    ...




--
View this message in context: 
http://apache-ignite-users.70518.x6.nabble.com/Data-Cache-memory-crash-tp341p344.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Reply via email to