ldap: reset cache when a user is deleted
When a user is deleted from ldap, reset both caches used by the source
otherwise the search is not performed again and exceptions such as
UnknownEid: No entity with eid 74078 in the repository
will occur
--- a/server/sources/ldapuser.py Sat May 29 09:58:23 2010 +0000
+++ b/server/sources/ldapuser.py Sat May 29 10:03:50 2010 +0000
@@ -513,7 +513,7 @@
eid, base)
entity = session.entity_from_eid(eid, 'CWUser')
self.repo.delete_info(session, entity, self.uri, base)
- self._cache.pop(base, None)
+ self.reset_cache()
return []
## except ldap.REFERRAL, e:
## cnx = self.handle_referral(e)