-
Notifications
You must be signed in to change notification settings - Fork 786
Easily discover groups in authorization plugins #1527
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
b089edb
to
fd73308
Compare
*/ | ||
public Set<Project> getAllProjects() { | ||
Set<Project> projectsTmp = new TreeSet<>(); | ||
for (Project p : getRepositories()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the getRepositories()
name is confusing to me as it clashes with the Repository
object.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree however I couldn't think of a better name for the projet-repository type (listed on the main page under the search form). Do you have better idea?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I understand it correctly, the repositories
contains projects with at least one Repository
(according to populateGroups()
so maybe it shall be named projectsWithRepo
or such ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
filed #1553
} | ||
|
||
private void discoverGroup(String group, HttpServletRequest request, Set<String> descendants) { | ||
private void discoverGroup(String group, HttpServletRequest request) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
javadoc would be nice
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added
- adding a javadoc
fd73308
to
8adb7a6
Compare
This expects the #1525 to be merged as it already implements the new interface.
This change moves the responsibility of a group discovery
to the opengrok code and the plugin can just call the new methods if it wants to add all subgroups/repositories/.. to the allowed set.