I have a Spring-Data LDAP repository configured as the following:
public interface LdapUserRepository extends LdapRepository<LdapUser> {
Set<LdapUser> findByNameLike(String name);
Optional<LdapUser> findByAccount(String account);
Optional<LdapUser> findByEmail(String email);
Optional<LdapUser> findByEmailAndPassword(String email, String password);
}
Everything looks fine except by the fact that some attributes are being not fetched. For instance, I have an employeeID
on LDAP user and being mapped on my LdapUser as the following:
@Attribute(name = "employeeID", readonly = true)
private String document;
I've checked and it's correctly populated on my directory:
When I query an User through (e.g) Optional<LdapUser> findByAccount(String account)
almost everything comes populated except by employeeID
mappend on document
field.
I'm also able to fetch it by querying it through a non-spring-data way.