/** * Clears the distributed region. * @param region The region to be cleared. * @throws CacheException */ public final static void clearRegion(Region region) throws CacheException { if (region == null) { return; } region.clear(); }
public static void clearMethod(){ try{ region.clear(); } catch(Exception ex){ ex.printStackTrace(); } }
public void run2() throws CacheException { try{ region.clear(); } catch(RegionDestroyedException rdex){ fail("Should NOT have thrown RegionDestroyedException"); } } }
public static void clearMethod(){ try{ region.clear(); } catch(Exception ex){ ex.printStackTrace(); } }
public static void clearMethod(){ try{ region.clear(); } catch(Exception ex){ ex.printStackTrace(); } }
public void run2() throws CacheException { try{ region.clear(); }catch(Exception ex){ ex.printStackTrace(); } } };//end of clear
public static void clearMethod(){ try{ region.clear(); } catch(Exception ex){ ex.printStackTrace(); } }
@Override public void testClearRegistry(){ idToType.clear(); enumToId.clear(); typeToId.clear(); }
public void run() { try{Thread.sleep(3*1000);}catch(InterruptedException ex){fail("interrupted");} mirroredRegion.clear(); assertEquals(0, mirroredRegion.size()); } });
public void clearSharedConfiguration() throws Exception { Region<String, Configuration> configRegion = getConfigurationRegion(); if (configRegion != null) { configRegion.clear(); } }
public void run2()throws CacheException{ region.put(new Integer(1), new String("first")); region.put(new Integer(2), new String("second")); region.put(new Integer(3), new String("third")); region.clear(); assertEquals(0, region.size()); } }
public void run2() throws CacheException { region.clear(); getLogWriter().fine("region is cleared"); } }
public void clear() { try { preOp(); this.realRegion.clear(); } finally { postOp(); } }
public void clear() { try { preOp(); this.realRegion.clear(); } finally { postOp(); } }
@Override public void run2() throws CacheException { Set<Region<?, ?>> rootRegions = getCache().rootRegions(); if (rootRegions != null) { for (Region<?, ?> region : rootRegions) { region.clear(); } } disconnectFromDS(); } });
@Override public void run() { Cache cache = getCache(); Region region = cache.getRegion(DATA_REGION_NAME_PATH); assertNotNull(region); region.clear(); } };
public void testQueriesWithPrimaryKeyIndex() throws Exception { Index index = qs.createKeyIndex("index3", "secId", "/exampleRegion"); assertTrue(index instanceof PrimaryKeyIndex); putPdxInstances(); executeQueriesValidateResults(INDEX_TYPE_PRIMARYKEY); r.clear(); putHeterogeneousObjects(); executeQueriesValidateResults(INDEX_TYPE_PRIMARYKEY); qs.removeIndex(index); r.clear(); }
public static void clearTask() { CachePerfClient c = new CachePerfClient(); c.initialize(); if (c.cache instanceof GemFireCacheTestImpl) { Region r = ((GemFireCacheTestImpl)c.cache).getRegion(); r.clear(); } else { String s = "clear() not supported for " + c.cache; throw new HydraConfigException(s); } }
/** * Make sure the disk region stats are set to zero when the region is cleared. */ public void testClearAndStats() throws Exception { DiskRegion dr = ((LocalRegion)testRegion).getDiskRegion(); assertEquals(0, dr.getStats().getNumEntriesInVM()); // put a value in the region testRegion.put(new Long(1), new Long(1)); assertEquals(1, dr.getStats().getNumEntriesInVM()); testRegion.clear(); assertEquals(0, dr.getStats().getNumEntriesInVM()); }
public void run2()throws CacheException { getLogWriter().info("### Clearing the region on the server ###"); Region region = getCache().getRegion("/root/" + cqDUnitTest.regions[0]); for (int i = 1; i <=5; i++) { region.put(CqQueryDUnitTest.KEY+i, new Portfolio(i)); } region.clear(); } });