Map configuration
This is used to configure how map data is stored within the cluster, either individual named maps or a cluster-wide default.
Maximum size and eviction
Maximum size policies include:
- PER_NODE
- PER_PARTITION
- USED_HEAP_SIZE
- USED_HEAP_PERCENTAGE
- FREE_HEAP_SIZE
- FREE_HEAP_PERCENTAGE
Eviction policies include:
- LRU: Least Recently Used
- LFU: Least Frequently Used
- NONE
<map name="default"> <max-size policy="PER_NODE">10</max-size> <eviction-policy>LFU</eviction-policy> <eviction-percentage>20</eviction-percentage> </map> config.getMapConfig("default") .setMaxSizeConfig(new MaxSizeConfig(10, MaxSizePolicy.PER_NODE)) .setEvictionPolicy(EvictionPolicy.LFU) .setEvictionPercentage(20);
Backup copies
Backup = Synchronous copies
Async = Asynchronous copies
Total ...
Get Getting Started with Hazelcast - Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.