mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Various changes to keep Hibernate session caches from growing without bound.
Deleting AVM locks is considerably faster which makes large submits faster. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6935 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -339,7 +339,10 @@ public class AVMRepository
|
||||
}
|
||||
dir.putChild(name, child);
|
||||
fLookupCache.onWrite(pathParts[0]);
|
||||
return child.getDescriptor(parent.getPath(), name, parent.getIndirection(), parent.getIndirectionVersion());
|
||||
AVMNodeDescriptor desc = child.getDescriptor(parent.getPath(), name, parent.getIndirection(), parent.getIndirectionVersion());
|
||||
fAVMNodeDAO.flush();
|
||||
fAVMNodeDAO.evict(child);
|
||||
return desc;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2481,6 +2484,7 @@ public class AVMRepository
|
||||
LayeredDirectoryNode dir = (LayeredDirectoryNode)node;
|
||||
dir.flatten(name);
|
||||
fAVMNodeDAO.flush();
|
||||
fAVMNodeDAO.evict(dir);
|
||||
}
|
||||
finally
|
||||
{
|
||||
@@ -2511,7 +2515,10 @@ public class AVMRepository
|
||||
throw new AVMNotFoundException("Path not found.");
|
||||
}
|
||||
AVMNode node = lPath.getCurrentNode();
|
||||
return node.getDescriptor(lPath);
|
||||
AVMNodeDescriptor desc = node.getDescriptor(lPath);
|
||||
fAVMNodeDAO.flush();
|
||||
fAVMNodeDAO.evict(node);
|
||||
return desc;
|
||||
}
|
||||
finally
|
||||
{
|
||||
@@ -2730,6 +2737,8 @@ public class AVMRepository
|
||||
{
|
||||
throw new AVMNotFoundException("Node not found: " + desc);
|
||||
}
|
||||
return node.getAspects();
|
||||
Set<QName> aspects = node.getAspects();
|
||||
fAVMNodeDAO.evict(node);
|
||||
return aspects;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user