/** {@inheritDoc} */ @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception { IgniteConfiguration cfg = super.getConfiguration(gridName); cfg.setPeerClassLoadingEnabled(false); cfg.setDeploymentMode(depMode); if (initGar) { UriDeploymentSpi depSpi = new UriDeploymentSpi(); depSpi.setUriList(Collections.singletonList(garFile)); cfg.setDeploymentSpi(depSpi); } ((TcpDiscoverySpi) cfg.getDiscoverySpi()).setHeartbeatFrequency(500); return cfg; }
/** {@inheritDoc} */ @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception { IgniteConfiguration cfg = super.getConfiguration(gridName); TcpDiscoverySpi spi = new TcpDiscoverySpi(); spi.setIpFinder(IP_FINDER); cfg.setDiscoverySpi(spi); cfg.setIncludeProperties(); cfg.setIncludeEventTypes(EVT_TASK_FAILED, EVT_TASK_FINISHED, EVT_JOB_MAPPED); cfg.setConnectorConfiguration(null); cfg.setPeerClassLoadingEnabled(true); if (useCache) { CacheConfiguration cc = defaultCacheConfiguration(); cc.setCacheMode(PARTITIONED); cc.setNearConfiguration(null); cc.setWriteSynchronizationMode(FULL_SYNC); cc.setStartSize(ENTRY_CNT / GRID_CNT); cc.setSwapEnabled(false); cc.setBackups(1); cfg.setCacheSanityCheckEnabled(false); cfg.setCacheConfiguration(cc); } else cfg.setCacheConfiguration(); return cfg; }