how to delete all entries ldap java
-
20-12-2019 - |
Frage
I have an application in Java, using Spring LDAP and Java Naming. The problem is when I delete a branch that contains entries. example:
root
|
|----A
| |
| |--A1
| |
| |----A2
| |
| |---A3
|
|
|-----B
When I try to delete the branch A, sends me the following exception:
[LDAP: error code 66 - subordinate objects must be deleted first]
Please help me! thank you!
Greetings.!
Lösung
If you are using Spring LDAP, you should be able to accomplish this using LdapTemplate#unbind method that takes 'recursive' argument:
Andere Tipps
Unless the LDAP server supports the TreeDelete extended operation or request control, whatever it is, and you can find a Java implementation of the client side code, you will have to traverse the subtree and delete the entries bottom-up.
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow