use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class IgnitePdsMultiNodePutGetRestartTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(gridName);
DataStorageConfiguration memCfg = new DataStorageConfiguration().setDefaultDataRegionConfiguration(new DataRegionConfiguration().setMaxSize(100 * 1024 * 1024).setPersistenceEnabled(true)).setWalMode(WALMode.LOG_ONLY);
cfg.setDataStorageConfiguration(memCfg);
CacheConfiguration ccfg = new CacheConfiguration();
ccfg.setIndexedTypes(Integer.class, DbValue.class);
ccfg.setRebalanceMode(CacheRebalanceMode.NONE);
ccfg.setAffinity(new RendezvousAffinityFunction(false, 32));
ccfg.setWriteSynchronizationMode(CacheWriteSynchronizationMode.FULL_SYNC);
cfg.setCacheConfiguration(ccfg);
TcpDiscoverySpi discoSpi = new TcpDiscoverySpi();
discoSpi.setIpFinder(IP_FINDER);
cfg.setDiscoverySpi(discoSpi);
cfg.setMarshaller(null);
BinaryConfiguration bCfg = new BinaryConfiguration();
bCfg.setCompactFooter(false);
cfg.setBinaryConfiguration(bCfg);
return cfg;
}
use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class IgnitePdsRemoveDuringRebalancingTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(gridName);
cfg.setCacheConfiguration(new CacheConfiguration().setAtomicityMode(CacheAtomicityMode.TRANSACTIONAL).setBackups(1).setWriteSynchronizationMode(CacheWriteSynchronizationMode.FULL_SYNC).setRebalanceMode(CacheRebalanceMode.SYNC));
DataStorageConfiguration memCfg = new DataStorageConfiguration().setDefaultDataRegionConfiguration(new DataRegionConfiguration().setMaxSize(100 * 1024 * 1024).setPersistenceEnabled(true).setSwapPath(DFLT_STORE_DIR)).setWalMode(WALMode.LOG_ONLY).setPageSize(1024).setConcurrencyLevel(Runtime.getRuntime().availableProcessors() * 4);
cfg.setDataStorageConfiguration(memCfg);
cfg.setDiscoverySpi(new TcpDiscoverySpi().setIpFinder(IP_FINDER));
return cfg;
}
use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class IgniteStableBaselineCachePutAllFailoverTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String igniteInstanceName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(igniteInstanceName);
cfg.setDataStorageConfiguration(new DataStorageConfiguration().setDefaultDataRegionConfiguration(new DataRegionConfiguration().setPersistenceEnabled(true).setInitialSize(200 * 1024 * 1024).setMaxSize(200 * 1024 * 1024).setCheckpointPageBufferSize(200 * 1024 * 1024)));
return cfg;
}
use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class IgnitePdsCacheRestoreTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String igniteInstanceName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(igniteInstanceName);
((TcpDiscoverySpi) cfg.getDiscoverySpi()).setIpFinder(IP_FINDER);
if (ccfgs != null) {
cfg.setCacheConfiguration(ccfgs);
ccfgs = null;
}
DataStorageConfiguration memCfg = new DataStorageConfiguration().setDefaultDataRegionConfiguration(new DataRegionConfiguration().setMaxSize(10 * 1024 * 1024).setPersistenceEnabled(true)).setPageSize(4 * 1024).setWalMode(WALMode.LOG_ONLY);
memCfg.setDataRegionConfigurations(new DataRegionConfiguration().setMaxSize(10 * 1024 * 1024).setName(NO_PERSISTENCE_REGION).setPersistenceEnabled(false));
cfg.setDataStorageConfiguration(memCfg);
return cfg;
}
use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class IgnitePdsDataRegionMetricsTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String igniteInstanceName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(igniteInstanceName);
((TcpDiscoverySpi) cfg.getDiscoverySpi()).setIpFinder(IP_FINDER);
DataStorageConfiguration memCfg = new DataStorageConfiguration().setDefaultDataRegionConfiguration(new DataRegionConfiguration().setInitialSize(INIT_REGION_SIZE).setPersistenceEnabled(true).setMetricsEnabled(true));
cfg.setDataStorageConfiguration(memCfg);
CacheConfiguration<Object, Object> ccfg = new CacheConfiguration<>().setName(DEFAULT_CACHE_NAME).setCacheMode(CacheMode.PARTITIONED).setBackups(1);
cfg.setCacheConfiguration(ccfg);
return cfg;
}
Aggregations