Removing notifications for users no longer in the system

I have an interesting problem.

Our users authenticate to xwiki via ldap/active directory. After several years, we have users that we’ve removed from the active directory. However in the wiki, these users no longer appear, but somehow the addresses are still receiving notifications for watched pages.

Is there anyway to find and remove these ghost notifications for users no longer present in the system? Any advice would be appreciated.


Anyone? Any hints or suggestions welcome.

Hi maybe there’s a memory cache somewhere, did you try to restart xwiki to see if that changes anything?


no, it’s not that.

the xwiki installation has been upgraded/restarted several times since the problem occurred.

the user object exists in the database, but no longer exists in the AD/ldap directory, thus the user object is not directly accessible in xwiki, and the notification settings for that user still exist.

Ah ok, I thought the users had been removed in XWiki since you said:

I don’t know the LDAP code at all so I don’t know how it removes users and whether there’s a config option for it or not. If it’s not done automatically I guess you have to remove the users manually in the wiki for now. If the feature is missing, it could be good to create a jira for it.

Someone with better knowledge of XWiki’s LDAP impl. should comment on this since I have no clue :slight_smile:

I’m not exactly sure what happens either, all I can tell is that the user is no longer visible in the user list, but the xwikiobjects table contains several records related to that no longer existent user.


*SELECT xwo_number, xwo_classname FROM xwikixwiki.xwikiobjects where xwo_name like ‘XWiki.aaryn%’;

xwo_number xwo_classname
7 XWiki.Notifications.Code.NotificationPreferenceClass
6 XWiki.Notifications.Code.NotificationPreferenceClass
5 XWiki.Notifications.Code.NotificationPreferenceClass
4 XWiki.Notifications.Code.NotificationPreferenceClass
3 XWiki.Notifications.Code.NotificationPreferenceClass
2 XWiki.Notifications.Code.NotificationPreferenceClass
1 XWiki.Notifications.Code.NotificationPreferenceClass
0 XWiki.LDAPProfileClass
0 XWiki.WatchListClass
0 XWiki.XWikiUsers
0 XWiki.Notifications.Code.NotificationPreferenceClass
0 Dashboard.UserDashboardPreferencesClass
0 XWiki.XWikiRights

How does xwiki normally handle user deletion - assuming we are only using xwiki user logins. Does it clean up the notifications of users no longer in the system? Do pages created and owned by that user still show who edited it? Does the ownership get reassigned?

Hmm, I may have to setup another installation to find out what happens under these circumstances. Whatever it is, the ldap implementation should be doing the “same thing”