Marco, If you access some records, that are stored in the off-heap memory, then you have to wait, while Ignite is deserializing the data and copying it to Java heap. But if the needed entry is already available in Java heap, Ignite doesn't have to perform these steps to return the result, it can just give you what it already has. So, the idea behind a Java heap cache is to make access to some specific entries faster. The entries, that are kept on the heap will be accessed way faster, than the once, that are stored in off-heap memory.
Note, that all of this is true only for the local records. If you have multiple nodes, and you do a lot of cross-node reads, then Java heap cache won't help you much. Denis ср, 28 февр. 2018 г. в 20:41, mamaco <mam...@163.com>: > Hi Denis, > > Thank you for the response, I appreciate it. > Yes, I agree with you, it could be done by various solutions, 'REST', > 'Event Listener' or any standalone instance. > According to the new design you mentioned, ignite stop the support of ' > *setMemoryMode(CacheMemoryMode.ONHEAP_TIERED)*' use Off-Heap in default > and force a switch setOnheapCacheEnabled in 2.0.0+ version, however, if we > can't get the entries straight from on-heap, what do on-heap policies stand > for (sort/fifo/random). Because no matter what we do, it returns the whole > thing. or the goal is just to make a faster cache? I don't mean to be > negative, I'm just curious about the truth under the hood. > > Marco > ------------------------------ > Sent from the Apache Ignite Users mailing list archive > <http://apache-ignite-users.70518.x6.nabble.com/> at Nabble.com. >