Hello,
I am using jackrabbit user manager to find out all the users in AEM repository. With userManager.finAuthorizables(Query) able to find out all the users. I want to get the immediate groups names of every user returned from above method.
For example if user "test" belongs "test-group" and if "test-group" belongs to "contributors" and when i say user.memberOf() (for test user), it is returning both "test-group" and "contributors" in group iterator. But i am interested to see only the immediate group ("test-group" only in above example.
Appreciated for a quick response.
Solved! Go to Solution.
Views
Replies
Total Likes
Yeah right, then I think you should write a custom service which will evaluate all possibilities and then return you the result.
How many approx user and groups do you have?
Views
Replies
Total Likes
Essentially, it lists all the groups which Users belongs to. I dont think any API available for this. What is the usecase you which needs this ?
Views
Replies
Total Likes
Few thoughts,
If its returning all the groups, it might return in a particular order. example from immediate to higher. Test this, and if order is same for all result then you get the index[0] of the returned array of group names.
Views
Replies
Total Likes
It will return groups from immediate to higher, but we can't say how many immediate groups that user belongs to. If user assigned to multiple groups, index 0 will just give one immediate group and we dont know how many immediate groups were there.
Views
Replies
Total Likes
Yeah right, then I think you should write a custom service which will evaluate all possibilities and then return you the result.
How many approx user and groups do you have?
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies