protected void queryTest(boolean useNamedRegion) throws Exception
{
// Bind a listener to the "local" cache
// Our region factory makes its CacheManager available to us
CacheManager localManager = TestCacheInstanceManager.getTestCacheManager(DualNodeTestUtil.LOCAL);
this.localCache = localManager.getCache(getEntityCacheConfigName(), true);
this.localListener = new CacheAccessListener();
localCache.addCacheListener(localListener);
TransactionManager localTM = localCache.getConfiguration().getRuntimeConfig().getTransactionManager();
// Bind a listener to the "remote" cache
CacheManager remoteManager = TestCacheInstanceManager.getTestCacheManager(DualNodeTestUtil.REMOTE);
this.remoteCache = remoteManager.getCache(getEntityCacheConfigName(), true);
this.remoteListener = new CacheAccessListener();
remoteCache.addCacheListener(remoteListener);
TransactionManager remoteTM = remoteCache.getConfiguration().getRuntimeConfig().getTransactionManager();