spring-ldap icon indicating copy to clipboard operation
spring-ldap copied to clipboard

Data loss when update() results in NameAlreadyBoundException

Open csnyder616 opened this issue 9 years ago • 0 comments
trafficstars

I'm attempting to rename an entry as part of the LdapTemplate.update() call. That method includes support for this: it checks if the ID has changed, and will call an unbind() and rebind() if necessary to handle the rename.

The issue occurs when the new ID is already in use: we get the expected NameAlreadyBoundException, but the entry has now ceased to exist. Since unbind() has been called, but bind() fails, the entry is gone.

csnyder616 avatar Oct 13 '16 15:10 csnyder616