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

89728: Merged V4.2-BUG-FIX (4.2.4) to HEAD-BUG-FIX (5.0/Cloud)
      89707: Merged V4.2.2 (4.2.2.14) to V4.2-BUG-FIX (4.2.4)
         86038: MNT-12458: CLONE - Setting synchronization.allowDeletions to false breaks Groups synchronization
            In ChainingUserRegistrySynchronizer.processGroups() was added check: !groupsToCreate.isEmpty().


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@94636 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Alan Davis
2015-01-31 10:42:18 +00:00
parent 21a5f76367
commit 79436c9bb4

View File

@@ -1427,7 +1427,7 @@ public class ChainingUserRegistrySynchronizer extends AbstractLifecycleBean
{
// If we got back some groups, we have to cross reference them with the set of known authorities
// MNT-9711 fix. If allowDeletions is false, there is no need to pull all users and all groups from LDAP during the full synchronization.
if (allowDeletions && (isFullSync || !this.groupParentAssocsToDelete.isEmpty()))
if ((allowDeletions || !groupsToCreate.isEmpty()) && (isFullSync || !this.groupParentAssocsToDelete.isEmpty()))
{
final Set<String> allZonePersons = newPersonSet();
final Set<String> allZoneGroups = new TreeSet<String>();