public EmbeddedCacheManager createCacheManager(int counter, int siteId, int machineId, int rackId) {
ConfigurationBuilder builder = getDefaultClusteredCacheConfig(getCacheMode(), false);
GlobalConfigurationBuilder globalConfigurationBuilder = GlobalConfigurationBuilder.defaultClusteredBuilder();
globalConfigurationBuilder.transport().machineId("m" + (machineId > 0 ? machineId : counter))
.rackId("r" + (rackId > 0 ? rackId : counter)).siteId("s" + (siteId > 0 ? siteId : counter));
EmbeddedCacheManager cm1 = TestCacheManagerFactory.createClusteredCacheManager(globalConfigurationBuilder,
builder);
cm1.defineConfiguration(CACHE_NAME, builder.build());