mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Fixed for MT Node Interceptor
- When MT is enabled, there is still a problem with the translation of NodeRefs for the UserUsage component git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@10795 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -236,6 +236,11 @@ public class UserUsageTrackingComponent
|
||||
|
||||
for (NodeRef personNodeRef : allPeople)
|
||||
{
|
||||
// Cater for Lucene indexes being stale
|
||||
if (!nodeService.exists(personNodeRef))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
Long currentUsage = (Long)nodeService.getProperty(personNodeRef, ContentModel.PROP_SIZE_CURRENT);
|
||||
if (currentUsage == null)
|
||||
{
|
||||
@@ -361,6 +366,11 @@ public class UserUsageTrackingComponent
|
||||
public Object execute() throws Throwable
|
||||
{
|
||||
NodeRef personNodeRef = personService.getPerson(username);
|
||||
if (!nodeService.exists(personNodeRef))
|
||||
{
|
||||
// Ignore
|
||||
return null;
|
||||
}
|
||||
contentUsageImpl.setUserStoredUsage(personNodeRef, currentUsage);
|
||||
usageService.deleteDeltas(personNodeRef);
|
||||
return null;
|
||||
|
Reference in New Issue
Block a user