Package org.gridgain.internal.rbac.roles
Class ConfigurationRoleStore
java.lang.Object
org.gridgain.internal.rbac.roles.ConfigurationRoleStore
Role store implementation based on distributed configuration
AuthorizationConfiguration.-
Constructor Summary
ConstructorsConstructorDescriptionConfigurationRoleStore(org.gridgain.internal.rbac.configuration.AuthorizationConfiguration authorizationConfiguration) Constructor. -
Method Summary
Modifier and TypeMethodDescription@Nullable org.gridgain.internal.rbac.roles.Roleget(LowerCaseString roleName) Gets entry by key.List<org.gridgain.internal.rbac.roles.Role>get(LowerCaseString... keys) Get entries by keys.Collection<org.gridgain.internal.rbac.roles.Role>getAll()Gets all entries.Map<LowerCaseString,org.gridgain.internal.rbac.roles.Role> Gets all entries with keys.putIfNotExists(LowerCaseString roleName, org.gridgain.internal.rbac.roles.Role role) Puts entry if given key does not exist.removeIfExists(LowerCaseString roleName) Removes entry if given key exists.updateIfExists(LowerCaseString roleName, Function<org.gridgain.internal.rbac.roles.Role, org.gridgain.internal.rbac.roles.Role> update) Updates entry if given key exists.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.gridgain.internal.rbac.store.Store
get, get, putIfNotExists, removeIfExists, updateIfExists
-
Constructor Details
-
ConfigurationRoleStore
public ConfigurationRoleStore(org.gridgain.internal.rbac.configuration.AuthorizationConfiguration authorizationConfiguration) Constructor.- Parameters:
authorizationConfiguration- Authorization configuration.
-
-
Method Details
-
putIfNotExists
public CompletableFuture<OperationResult> putIfNotExists(LowerCaseString roleName, org.gridgain.internal.rbac.roles.Role role) Description copied from interface:StorePuts entry if given key does not exist.- Specified by:
putIfNotExistsin interfaceStore<org.gridgain.internal.rbac.roles.Role>- Parameters:
roleName- Entry key.role- Entry value.- Returns:
- Operation result.
-
updateIfExists
public CompletableFuture<OperationResult> updateIfExists(LowerCaseString roleName, Function<org.gridgain.internal.rbac.roles.Role, org.gridgain.internal.rbac.roles.Role> update) Description copied from interface:StoreUpdates entry if given key exists.- Specified by:
updateIfExistsin interfaceStore<org.gridgain.internal.rbac.roles.Role>- Parameters:
roleName- Entry key.update- Update entry function.- Returns:
- Operation result.
-
removeIfExists
Description copied from interface:StoreRemoves entry if given key exists.- Specified by:
removeIfExistsin interfaceStore<org.gridgain.internal.rbac.roles.Role>- Parameters:
roleName- Entry key.- Returns:
- Operation result.
-
getAll
Description copied from interface:StoreGets all entries. If there is no entries at all, empty collection will be returned. -
getAllWithKeys
Description copied from interface:StoreGets all entries with keys. If there is no entries at all, empty map will be returned.- Specified by:
getAllWithKeysin interfaceStore<org.gridgain.internal.rbac.roles.Role>- Returns:
- Map from entry key to entry.
-
get
Description copied from interface:StoreGets entry by key. -
get
Description copied from interface:StoreGet entries by keys.
-