-
Notifications
You must be signed in to change notification settings - Fork 27
MemberSearch cleanup and polish #69
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
# See also `GitHub::Ldap#configure_member_search_strategy`. | ||
class Detect | ||
# Defines `active_directory_capability?` and necessary helpers. | ||
include GitHub::Ldap::Capabilities |
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.
This module feels like a premature extraction. It's specific to ActiveDirectory, and doesn't seem useful outside this context.
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.
@jch agree in some senses, but there are two separate classes that depend on the same behavior that didn't feel right duplicating in (the ActiveDirectory MemberSearch and MembershipValidation strategies). It's a mix of AD-specific feature detection with general capability exposure.
I'm not crazy about it, but it unblocks this PR and can be easily changed in the future when a better approach can be considered, particularly because it's internal only. I think this need will diminish with the changes you outline in #69 (comment), so it is likely temporary.
Thoughts?
@jch so to summarize what needs to be addressed in a followup PR:
Does that sound like a reasonable breakdown? Some of it may be more specific that necessary, partly because I think there are a few directions we could go that would result in cleaner internals with equivalent functionality, but exactly what I've not concluded. |
👍 to shipping if you feel it'll unblock your other work. Left comments inline about refactorings. |
As a follow up to #64, this renames
GitHub::Ldap::Members
member search strategy toGitHub::Ldap::MemberSearch
and aims to finish up any significant missing pieces:cc @jch