On 4 February 2016 at 00:55, Sam Ruby <[email protected]> wrote:
> On Wed, Feb 3, 2016 at 7:02 PM, sebb <[email protected]> wrote:
>> On 3 February 2016 at 23:23, Sam Ruby <[email protected]> wrote:
>>> Commit 8745cc5399c8bf8a13a20dd5e8a41bc59161d0cf:
>>>     Cleanup only - no functional changes
>>>     *) Use documented interface for getting the LDAP hostname
>>
>> Where is the ldap library documented?
>
> Not very well :-(
>
> The LDAP library chosen appears to be a thin layer over the C
> interface, and I was able to piece together the interface using some
> guesswork.  I used irb, but the following reproduces what I did:
>
> ruby -r whimsy/asf -e "p ASF.init_ldap.methods"
> ruby -r whimsy/asf -e "p LDAP.constants.grep /HOST/"
>
> ... followed by google searches on the result.
>
>> There seem to be quite a few ldap libraries for Ruby.
>> It's not obvious which one was chosen.
>
> The one used can be found here:
>
> https://github.com/apache/whimsy/blob/master/asf.gemspec#L26

That says 'ruby-ldap'

> https://github.com/apache/whimsy/blob/master/lib/whimsy/asf/ldap.rb#L32

That is just 'ldap'

These appear to be different, but perhaps I'm missing something?

I could not find a plain 'ldap' on RubyGems.org, so where does that come from?

>
> I'm not sure why I picked that one at the time.  This one appears to
> be more popular:
>
> https://rubygems.org/gems/net-ldap/
>
> All calls to LDAP are isolated in a single source file, so should
> switching be something worth considering, the changes should be
> minimal.
>
> - Sam Ruby

Reply via email to