use of org.apache.ignite.cache.affinity.rendezvous.RendezvousAffinityFunction in project ignite by apache.
the class CacheReplicatedRendezvousAffinityExcludeNeighborsMultiNodeFullApiSelfTest method cacheConfiguration.
/** {@inheritDoc} */
@Override
protected CacheConfiguration cacheConfiguration(String igniteInstanceName) throws Exception {
CacheConfiguration cfg = super.cacheConfiguration(igniteInstanceName);
cfg.setAffinity(new RendezvousAffinityFunction(true));
return cfg;
}
use of org.apache.ignite.cache.affinity.rendezvous.RendezvousAffinityFunction in project ignite by apache.
the class CacheReplicatedRendezvousAffinityMultiNodeFullApiSelfTest method cacheConfiguration.
/** {@inheritDoc} */
@Override
protected CacheConfiguration cacheConfiguration(String igniteInstanceName) throws Exception {
CacheConfiguration cfg = super.cacheConfiguration(igniteInstanceName);
cfg.setAffinity(new RendezvousAffinityFunction());
return cfg;
}
use of org.apache.ignite.cache.affinity.rendezvous.RendezvousAffinityFunction in project ignite by apache.
the class DemoCachesLoadService method cacheConfiguration.
/**
* Create base cache configuration.
*
* @param name cache name.
* @return Cache configuration with basic properties set.
*/
private static CacheConfiguration cacheConfiguration(String name) {
CacheConfiguration ccfg = new CacheConfiguration<>(name);
ccfg.setAffinity(new RendezvousAffinityFunction(false, 32));
ccfg.setQueryDetailMetricsSize(10);
ccfg.setStatisticsEnabled(true);
ccfg.setSqlFunctionClasses(SQLFunctions.class);
return ccfg;
}
Aggregations