//System.out.println("parentSiteNodeId:" + parentSiteNodeId);
if(siteNodeId == null || siteNodeId.equals(""))
{
try
{
SiteNodeVersionVO snvVO = SiteNodeVersionController.getController().getSiteNodeVersionVOWithId(new Integer(entityId));
siteNodeId = ""+snvVO.getSiteNodeId();
if(repositoryId == null)
{
SiteNodeVO snVO = SiteNodeController.getController().getSiteNodeVOWithId(snvVO.getSiteNodeId());
repositoryId = ""+snVO.getRepositoryId();
parentSiteNodeId = ""+snVO.getParentSiteNodeId();
}
}
catch (Exception e2)
{
logger.info("Error getting siteNodeVersion " + entityId);
}
}
if(siteNodeId != null)
{
logger.info("Before flushGroup2...");
if(cacheName.equals("pageCacheExtra"))
{
PageCacheHelper.getInstance().notify("siteNode_" + siteNodeId);
//clearFileCacheForGroup(cacheInstance, "siteNode_" + siteNodeId);
}
else
{
cacheInstance.flushGroup("siteNode_" + siteNodeId);
cacheInstance.flushGroup("" + siteNodeId);
}
if(siteNodeId != null && (cacheName.equals("childSiteNodesCache") || cacheName.equals("childPagesCache") || cacheName.equals("siteNodeCache") || cacheName.equals("componentPropertyCacheRepoGroups") || cacheName.equals("componentPropertyVersionIdCacheRepoGroups")))
{
if(cacheName.equals("componentPropertyCacheRepoGroups") || cacheName.equals("componentPropertyVersionIdCacheRepoGroups"))
{
cacheInstance.flushGroup("" + repositoryId);
logger.info("Clearing componentPropertyCacheRepoGroups for repo:" + repositoryId);
}
if(parentSiteNodeId != null)
{
cacheInstance.flushGroup("siteNode_" + parentSiteNodeId);
cacheInstance.flushGroup("" + parentSiteNodeId);
cacheInstance.flushEntry("" + parentSiteNodeId);
logger.info("Clearing for:" + parentSiteNodeId);
}
}
logger.info("After flushGroup2...");
}
}
catch(Exception se)
{
logger.warn("Missing siteNode version: " + se.getMessage(), se);
}
}
else
{
try
{
if((cacheName.equals("childSiteNodesCache") || cacheName.equals("childPagesCache") || cacheName.equals("siteNodeCache") || cacheName.equals("componentPropertyCacheRepoGroups") || cacheName.equals("componentPropertyVersionIdCacheRepoGroups")))
{
SiteNodeVersionVO snvVO = SiteNodeVersionController.getController().getSiteNodeVersionVOWithId(new Integer(entityId));
SiteNodeVO snVO = SiteNodeController.getController().getSiteNodeVOWithId(snvVO.getSiteNodeId());
Integer repositoryId = snVO.getRepositoryId();
Integer parentSiteNodeId = snVO.getParentSiteNodeId();
if(cacheName.equals("componentPropertyCacheRepoGroups") || cacheName.equals("componentPropertyVersionIdCacheRepoGroups"))