Skip to content

Auto-configure an ObjectDirectoryMapper bean and configure LdapTemplate to use it #44249

Closed as not planned
@jzheaux

Description

@jzheaux

Related to spring-projects/spring-ldap#633, it would be nice if Spring Boot picked up a ObjectDirectoryMapper bean:

@Bean
@ConditionalOnMissingBean(LdapOperations.class)
public LdapTemplate ldapTemplate(LdapProperties properties, ContextSource contextSource, 
        ObjectDirectoryMapper objectDirectoryMapper) {
        // ...
	LdapTemplate ldapTemplate = new LdapTemplate(contextSource);
	ldapTemplate.setObjectDirectoryMapper(objectDirectoryMapper);
	return ldapTemplate;
}

As of Spring LDAP 3.3.0-M2, Spring Boot can import ObjectDirectoryMapperConfiguration to publish a ObjectDirectoryMapper bean.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions