Source:
void start() { switch (configurationManager.getGlobalConfiguration().globalState().configurationStorage()) { case IMMUTABLE: this.localConfigurationManager = new ImmutableLocalConfigurationStorage(); break; case VOLATILE: this.localConfigurationManager = new VolatileLocalConfigurationStorage(); break; case OVERLAY: this.localConfigurationManager = new OverlayLocalConfigurationStorage(); break; default: this.localConfigurationManager = configurationManager.getGlobalConfiguration().globalState().configurationStorageClass().get(); break; } internalCacheRegistry.registerInternalCache( CONFIG_STATE_CACHE_NAME, new ConfigurationBuilder().build(), EnumSet.of(InternalCacheRegistry.Flag.GLOBAL)); parserRegistry = new ParserRegistry(); localConfigurationManager.initialize(cacheManager, configurationManager, executorService); Map<String, Configuration> stateConfigurations = localConfigurationManager.loadAll(); for (Map.Entry<ScopedState, Object> e : getStateCache().entrySet()) { if (CACHE_SCOPE.equals(e.getKey().getScope())) { String cacheName = e.getKey().getName(); CacheState cacheState = (CacheState) e.getValue(); Configuration existing = stateConfigurations.get(cacheName); if (existing != null) { Configuration configuration = buildConfiguration(cacheName, cacheState); if (!existing.matches(configuration)) { throw CONFIG.incompatibleClusterConfiguration(cacheName, configuration, existing); } else { stateConfigurations.remove(cacheName); } } } } for (Map.Entry<ScopedState, Object> e : getStateCache().entrySet()) { if (CACHE_SCOPE.equals(e.getKey().getScope())) { String cacheName = e.getKey().getName(); CacheState cacheState = (CacheState) e.getValue(); uncheckedAwait(createCacheLocally(cacheName, cacheState)); } } GlobalConfigurationStateListener stateCacheListener = new GlobalConfigurationStateListener(this); getStateCache().addListener(stateCacheListener, new ScopeFilter(CACHE_SCOPE)); List<CompletableFuture<Configuration>> all = stateConfigurations.entrySet().stream().map((entry) -> getOrCreateCache(entry.getKey(), entry.getValue(), EnumSet.noneOf(CacheContainerAdmin.AdminFlag.class)) ).collect(Collectors.toList()); uncheckedAwait(CompletableFutures.sequence(all)); }

Target:
void start() { switch (configurationManager.getGlobalConfiguration().globalState().configurationStorage()) { case IMMUTABLE: this.localConfigurationManager = new ImmutableLocalConfigurationStorage(); break; case VOLATILE: this.localConfigurationManager = new VolatileLocalConfigurationStorage(); break; case OVERLAY: this.localConfigurationManager = new OverlayLocalConfigurationStorage(); break; default: this.localConfigurationManager = configurationManager.getGlobalConfiguration().globalState().configurationStorageClass().get(); break; } internalCacheRegistry.registerInternalCache( CONFIG_STATE_CACHE_NAME, new ConfigurationBuilder().build(), EnumSet.of(InternalCacheRegistry.Flag.GLOBAL)); parserRegistry = new ParserRegistry(); localConfigurationManager.initialize(cacheManager, configurationManager, executorService); Map<String, Configuration> persistedConfigurations = localConfigurationManager.loadAll(); for (Map.Entry<ScopedState, Object> e : getStateCache().entrySet()) { if (CACHE_SCOPE.equals(e.getKey().getScope())) { String cacheName = e.getKey().getName(); CacheState cacheState = (CacheState) e.getValue(); Configuration persisted = persistedConfigurations.get(cacheName); if (persisted != null) { Configuration configuration = buildConfiguration(cacheName, cacheState); if (!persisted.matches(configuration)) { throw CONFIG.incompatibleClusterConfiguration(cacheName, configuration, persisted); } else { persistedConfigurations.remove(cacheName); } } } } for (Map.Entry<ScopedState, Object> e : getStateCache().entrySet()) { if (CACHE_SCOPE.equals(e.getKey().getScope())) { String cacheName = e.getKey().getName(); CacheState cacheState = (CacheState) e.getValue(); uncheckedAwait(createCacheLocally(cacheName, cacheState)); } } GlobalConfigurationStateListener stateCacheListener = new GlobalConfigurationStateListener(this); getStateCache().addListener(stateCacheListener, new ScopeFilter(CACHE_SCOPE)); List<CompletableFuture<Configuration>> all = persistedConfigurations.entrySet().stream().map((entry) -> getOrCreateCache(entry.getKey(), entry.getValue(), EnumSet.noneOf(CacheContainerAdmin.AdminFlag.class)) ).collect(Collectors.toList()); uncheckedAwait(CompletableFutures.sequence(all)); }