use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class AuthenticationProcessorNodeRestartTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String igniteInstanceName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(igniteInstanceName);
if (getTestIgniteInstanceIndex(igniteInstanceName) == CLI_NODE)
cfg.setClientMode(true);
TcpDiscoverySpi spi = new TcpDiscoverySpi();
spi.setIpFinder(IP_FINDER);
cfg.setDiscoverySpi(spi);
cfg.setAuthenticationEnabled(true);
cfg.setDataStorageConfiguration(new DataStorageConfiguration().setDefaultDataRegionConfiguration(new DataRegionConfiguration().setPersistenceEnabled(true)));
return cfg;
}
use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class IgnitePdsCheckpointSimpleTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String igniteInstanceName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(igniteInstanceName);
DataRegionConfiguration regCfg = new DataRegionConfiguration().setPersistenceEnabled(true);
DataStorageConfiguration dsCfg = new DataStorageConfiguration().setPageSize(4 * 1024).setDefaultDataRegionConfiguration(regCfg).setCheckpointFrequency(TimeUnit.SECONDS.toMillis(10));
return cfg.setDataStorageConfiguration(dsCfg);
}
use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class IgnitePdsCheckpointSimulationWithRealCpDisabledTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(gridName);
CacheConfiguration ccfg = new CacheConfiguration(cacheName);
ccfg.setRebalanceMode(CacheRebalanceMode.NONE);
cfg.setCacheConfiguration(ccfg);
cfg.setDataStorageConfiguration(new DataStorageConfiguration().setCheckpointFrequency(500).setWalMode(WALMode.LOG_ONLY).setAlwaysWriteFullPages(true).setDefaultDataRegionConfiguration(new DataRegionConfiguration().setPersistenceEnabled(true)));
TcpDiscoverySpi discoSpi = new TcpDiscoverySpi();
discoSpi.setIpFinder(IP_FINDER);
cfg.setDiscoverySpi(discoSpi);
return cfg;
}
use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class IgnitePdsThreadInterruptionTest method storageConfiguration.
/**
* @return DataStorage configuration.
*/
private DataStorageConfiguration storageConfiguration() {
DataRegionConfiguration regionCfg = new DataRegionConfiguration().setInitialSize(10L * 1024L * 1024L).setMaxSize(10L * 1024L * 1024L).setPageEvictionMode(DataPageEvictionMode.RANDOM_LRU);
DataStorageConfiguration cfg = new DataStorageConfiguration().setWalMode(WALMode.LOG_ONLY).setWalFsyncDelayNanos(0).setPageSize(PAGE_SIZE).setFileIOFactory(new AsyncFileIOFactory());
cfg.setDefaultDataRegionConfiguration(regionCfg);
return cfg;
}
use of org.apache.ignite.configuration.DataRegionConfiguration in project ignite by apache.
the class IgniteUidAsConsistentIdMigrationTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
final IgniteConfiguration cfg = super.getConfiguration(gridName);
if (configuredConsistentId != null)
cfg.setConsistentId(configuredConsistentId);
final DataStorageConfiguration dsCfg = new DataStorageConfiguration();
if (placeStorageInTemp) {
final File tempDir = new File(System.getProperty("java.io.tmpdir"));
pstStoreCustomPath = new File(tempDir, "Store");
pstWalStoreCustomPath = new File(tempDir, "WalStore");
pstWalArchCustomPath = new File(tempDir, "WalArchive");
dsCfg.setStoragePath(pstStoreCustomPath.getAbsolutePath());
dsCfg.setWalPath(pstWalStoreCustomPath.getAbsolutePath());
dsCfg.setWalArchivePath(pstWalArchCustomPath.getAbsolutePath());
}
dsCfg.setDefaultDataRegionConfiguration(new DataRegionConfiguration().setMaxSize(32 * 1024 * 1024).setPersistenceEnabled(true));
cfg.setDataStorageConfiguration(dsCfg);
if (strLog != null)
cfg.setGridLogger(strLog);
return cfg;
}
Aggregations