On Confluence 9.2, when using event listeners, the getEntityNames() method of GroupMembershipsDeletedEvent is always empty

In one of my plugins, I need to be notified via an event listener whenever a group membership is deleted.So I used GroupMembershipsDeletedEvent, for example:

@EventListener
public void onGroupMemberRemoved(final GroupMembershipsDeletedEvent event) {
    ...
}

The problem is that event.getEntityNames() is always empty, and from the event object I can’t determine which user’s memberships were deleted.

Does anyone know why this happens?
Is there any way for the event to provide the list of deleted memberships?

PS: I delete the user in LDAP and then synchronize it with Confluence through User Directories.

Has no-one else experienced this?

When removing users manually in Confluence, the event contains all removed users. But when the users are removed from the group via LDAP, the event almost never contains the removed users. “Almost”, because in rare cases, it does…

@Kusal, I’m mentioning you because I know for sure that you are working on Confluence. :slight_smile:

@Kusal Sorry for mentioning you again, but we really need an answer why GroupMembershipsDeletedEvent:getEntityNames() is empty most of the time when users are removed via LDAP. Is there an alternative way to listen for group membership changes that works reliably?

Hi @Kusal& @cheinig

Any news on that?

Best wishes

Dominic