Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-9627

Add cache on computed groups

    XMLWordPrintable

    Details

      Description

      It would be nice to have some kind of cache on computed groups, especially when searching for a group in the user/group suggestion widget in the rights management tab.
      Indeed, in this case, the following stack is called:

      UserSuggestionActionsBean#getGroupsSuggestions(Object input)
      ...
      AbstractGroupComputer#hasGroup(String name)
      GroupComputer#getAllGroupIds()
      

      In the AbstractAttributeBasedGroupComputer#getAllGroupIds() implementation, we have this loop:

      for (String userId : getUM().getUserIds()) {
        ...
      }
      

      with getUM().getUserIds() retrieving all users from the user directory!

      When using an LDAP directory with thousands of entries we obviously get several occurrences of SizeLimitExceededException and the group search can take a very long time.

      So it could be interesting to be able to cache the computed groups (with a good invalidation mechanism, sine the purpose of computed groups is to be dynamically computed...), or maybe find a way not to fetch all the group members when searching for such groups.

        Attachments

          Activity

            People

            • Votes:
              1 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: