Merged HEAD-BUG-FIX (5.0/Cloud) to HEAD (5.0/Cloud)

78551: Merged V4.2-BUG-FIX (4.2.4) to HEAD-BUG-FIX (5.0/Cloud)
      77501: Merged DEV to V4.2-BUG-FIX (4.2.4)
         76291 : MNT-11511 : All tags are not displayed in repository when the number of nodes taggable is over 1000
            - Using tagscope api at search for tags quantity in repository


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@82595 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Erik Winlof
2014-09-03 12:32:55 +00:00
parent e429be8b8c
commit 3ccf71dc7b
4 changed files with 79 additions and 1 deletions

View File

@@ -0,0 +1,45 @@
package org.alfresco.repo.admin.patch.impl;
import org.alfresco.repo.admin.patch.AbstractPatch;
import org.alfresco.repo.model.Repository;
import org.alfresco.service.cmr.tagging.TaggingService;
import org.springframework.extensions.surf.util.I18NUtil;
public class AddTagScopeAspect extends AbstractPatch
{
/** The title we give to the batch process in progress messages / JMX. */
private static final String SUCCESS_MSG = "patch.addTagScopeAspect.result";
/** Services */
private TaggingService taggingService;
/** Repository object */
private Repository repository;
/**
* Sets the tagging service.
*
* @param taggingService
* the tagging service
*/
public void setTaggingService(TaggingService taggingService)
{
this.taggingService = taggingService;
}
/**
* @param repository repository object
*/
public void setRepository(Repository repository)
{
this.repository = repository;
}
@Override
protected String applyInternal() throws Exception
{
taggingService.addTagScope(repository.getCompanyHome());
return I18NUtil.getMessage(SUCCESS_MSG);
}
}