public class InMemoryNonAggregatingSearchStrategy extends AbstractInMemorySearchStrategy
SearchStrategy
which only return memberships associated with the canonical users directory.
This is considered the worse case SearchStrategy
to use as searching across multiple directories
will be done in-memory, potentially consuming a lot of memory. This is the same (in spirit) as what Crowd 2.8
and earlier would do by default.
Application.isMembershipAggregationEnabled()
activeDirectories, directoryManager
Constructor and Description |
---|
InMemoryNonAggregatingSearchStrategy(DirectoryManager directoryManager,
List<Directory> activeDirectories) |
Modifier and Type | Method and Description |
---|---|
<T> List<T> |
searchDirectGroupRelationships(MembershipQuery<T> query)
Searches for direct group relationships in any of the application's active assigned directories.
|
<T> List<T> |
searchNestedGroupRelationships(MembershipQuery<T> query)
Searches for direct and indirect (nested) group relationships in any of the application's active assigned directories.
|
doDirectDirectoryMembershipQuery, doNestedDirectoryMembershipQuery, getAggregatingAndSortingComparatorFor, searchGroups, searchUsers
public InMemoryNonAggregatingSearchStrategy(DirectoryManager directoryManager, List<Directory> activeDirectories)
public <T> List<T> searchDirectGroupRelationships(MembershipQuery<T> query)
SearchStrategy
When searching for the groups an entity is a member of,
the membership aggregation semantic
will determine whether only the owning directory (when false
) or all directories (when true
) will be searched.
public <T> List<T> searchNestedGroupRelationships(MembershipQuery<T> query)
SearchStrategy
If the directory does not support nested groups, this call will be equivalent to DirectoryManager.searchDirectGroupRelationships(long, com.atlassian.crowd.search.query.membership.MembershipQuery)
.
WARNING: this method could be very slow if the underlying RemoteDirectory does not employ caching.
When searching for the groups a user is a member of only the directory of the user (as determined by findUserByName) is searched. When searching for memberships of a group or groups a group is a member of all directories are searched and the results amalgamated.
Copyright © 2018 Atlassian. All rights reserved.