Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 244595

Re: Java heap space occurs by problem with Gemfire Region

$
0
0

Yes , this scenario is correct, and the problems is that in the servers when the threads is works the clear in the region are working , but the problems is wiith the clear in the other region in the other server.

 

I'll attach the xml file. The region is the "root-region".

 

And the code is the next:

 

 

private void snapshotCommonRegion(DeltaLoader loader, String regionName, Class<? extends BaseEntity> entityClass, Date toDate)
{
loader.addOperation(new UseRegionOperation(regionName));
Region<Object, Object> subRegion = getOrCreateSubRegion(regionName);
subRegion.clear();
for (BaseEntity domain : sourceRepository.findAllNotDeletedEntities(entityClass, toDate))
{
loader.addOperation(new PutOperation(domain));
subRegion.put(domain.getId(), domain);
}
}

 

 

 

private Region<Object, Object> getOrCreateSubRegion(String regionName)

{

Region<Object, Object> subRegion = rootRegion.getSubregion(regionName);

if (subRegion == null)

{

subRegion = rootRegion.createSubregion(regionName, rootRegion.getAttributes());

}

return subRegion;

}


Viewing all articles
Browse latest Browse all 244595

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>