private String getCurrentDnForRegisteredService(final RegisteredService rs) {
        val response = searchForServiceById(rs.getId());
        if (LdapUtils.containsResultEntry(response)) {
            return response.getEntry().getDn();
        }
        return null;
    }
Update the ldap entry with the given registered service.

@param rs the rs
@return the registered service
support/cas-server-support-ldap-service-registry/src/main/java/org/apereo/cas/adaptors/ldap/services/LdapServiceRegistry.java