Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

More than one instance of com.atlassian.confluence.internal.security.SpacePermissionManagerInternal

Witold Zabdyr August 21, 2025

Hi,

I need to remove space permissions for some specific groups. The current working code indicates that the removePermission() method in the SpacePermissionManager class is deprecated, and I'd like to switch to SpacePermissionManagerInternal as recommended.

Part of the current code, working correctly:

permissions.each {

spacePermissionManager.removePermission(it)

}

Part of the new code, not working:

def context = SpacePermissionContext.createDefault()

ComponentLocator.getComponent(SpacePermissionManagerInternal).removeAllPermissionsForGroup(oldGroup, context)


The new code generates an entry in the logs:

 More than one instance of com.atlassian.confluence.internal.security.SpacePermissionManagerInternal found but none of them has key spacePermissionManagerInternal

 
There's probably something wrong with our Confluence instance, but what? Any ideas?

Regards

1 answer

0 votes
Marc - Devoteam
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 21, 2025

Hi @Witold Zabdyr 

For cloud there is no SpacePermissionManager class for direct use in Confluence Cloud,

For Confluence Cloud, use the Confluence REST APIs, which allows the creation and modification of users, groups, and their roles within spaces. 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
ENTERPRISE
TAGS
AUG Leaders

Atlassian Community Events