About Active Directory DNS Locator
A locator for various Active Directory services like LDAP, Global Catalog, Kerberos, etc. via DNS SRV resource records.
It is meant to easily locate servers with the domain or forest name only without ever having to hard code any hostnames. A builder class with a fluent API supports you to construct an ActiveDirectoryDnsLocator
to locate host/port pairs with. Moreover, it plugs into the JNDI/LDAP Service Provider automatically with zero configuration.
Getting Started
Download the artifact, read the user guide and get started.
Origin of this Project
I was working with directory servers, Active Directory specifically, in many projects in my company for several years now and was tired of configuring hard coded hostnames which fail or vanish over and over again. For the time being I patched internal JDK code to discover servers automatically, but this wasn't something one can offer publically. Finally, I have filed JDK-8160768 and JDK-8161361, and they were solved after years of waiting. This project is now the result of the provided solution. This library has been in production in several projects, e.g., directly within Apache Tomcat or the Spring Framework, for several years now – with great success.