Uploaded image for project: 'Grouper'
  1. Grouper
  2. GRP-2328

Calling group.replaceMembers() to replace a direct group with its members deletes instead of replaces

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • 2.6.5
    • 2.4.0.patch
    • API
    • None

    Description

      groovy:000> oldGroup.replaceMembers(newGroup.members.collect {it.subject})
      2019-09-17 10:08:17,838: [main] INFO  Group.replaceMembers(1057) - existingMemberListSize: 14, deletedMemberCount: 1, groupName: unc:org:3103:middleware:admin, newMemberListSize: 13, addedMemberCount: 0, changedRecords: 1, operation: replaceMembers
      

      newGroup has 13 direct person members. OldGroup has newGroup as its only direct member, so 1 direct member and 13 indirect. I wanted oldGroup to have identical membership to newGroup, so 13 direct members.

      Calling oldGroup.replaceMembers() with the set of the 13 members did not work. It simply deleted newGroup as a member, without adding the people subjects.

      Attachments

        Issue Links

          Activity

            People

              chad.redman@at.internet2.edu Chad Redman (unc.edu)
              chad.redman@at.internet2.edu Chad Redman (unc.edu)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: