As we saw within the book, it is also possible to configure Hazelcast programmatically, this can provide for a higher application control of the cluster.
Set general properties
Config conf = new Config(); conf.setProperty("hazelcast.map.partition.count", "271");
conf.setInstanceName("my-instance");
conf.setLiteMember(true);
Get reference to map configuration
MapConfig citiesConf = conf.getMapConfig("cities");
Modify default behavior
citiesConf.setBackupCount(2); citiesConf.setAsyncBackupCount(1);
Add map index
citiesConf.addMapIndexConfig( new MapIndexConfig("country", false));