Open In App

Spring Data LDAP

Spring Data LDAP is a project that provides a familiar and consistent repository abstraction for Spring LDAP. It builds on top of Spring LDAP’s LdapTemplate and Object-Directory Mapping (ODM) features and provides repository implementations for CRUD operations on LDAP entries. Spring Data LDAP can be used to develop applications that access LDAP directories for a variety of purposes, such as:

Features

Dependency

Maven:

<dependency>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-ldap</artifactId>
<version>3.2.3</version>
</dependency>

Gradle:

dependencies {
implementation 'org.springframework.data:spring-data-ldap:3.2.3'
}

Configuration

The recommended way of configuring Spring LDAP is to use the custom XML configuration namespace. To make this available, you need to include the Spring LDAP namespace declaration in your bean file, as follows:

LDAP Entities

LDAP Repositories

Conclusion

Spring Data LDAP is a powerful tool that can be used to develop applications that access LDAP directories. It provides a familiar and consistent repository abstraction that makes it easy to develop applications that perform CRUD operations on LDAP entries.

Article Tags :