Interface WritableIdentityProvider

  • All Superinterfaces:
    Session
    All Known Implementing Classes:
    DbIdentityServiceProvider

    public interface WritableIdentityProvider
    extends Session

    SPI Interface for identity service implementations which offer read / write access to the user database.

    Author:
    Daniel Meyer
    • Method Detail

      • createNewUser

        User createNewUser​(String userId)

        Returns a new (transient) User object. The Object is not yet persistent and must be saved using the saveUser(User) method.

        NOTE: the implementation does not validate the uniqueness of the userId parameter at this time.

        Parameters:
        userId -
        Returns:
        an non-persistent user object.
      • unlockUser

        IdentityOperationResult unlockUser​(String userId)
        Allows unlocking a User object.
        Parameters:
        userId - the id of the User object to delete.
        Returns:
        the operation result object.
        Throws:
        AuthorizationException - if the user is not CAMUNDA_ADMIN
      • createNewGroup

        Group createNewGroup​(String groupId)

        Returns a new (transient) Group object. The Object is not yet persistent and must be saved using the saveGroup(Group) method.

        NOTE: the implementation does not validate the uniqueness of the groupId parameter at this time.

        Parameters:
        groupId -
        Returns:
        an non-persistent group object.
      • createNewTenant

        Tenant createNewTenant​(String tenantId)

        Returns a new (transient) Tenant object. The Object is not yet persistent and must be saved using the saveTenant(Tenant) method.

        NOTE: the implementation does not validate the uniqueness of the tenantId parameter at this time.

        Parameters:
        tenantId - the id of the new tenant
        Returns:
        an non-persistent tenant object.
      • createMembership

        IdentityOperationResult createMembership​(String userId,
                                                 String groupId)
        Creates a membership relation between a user and a group. If the user is already part of that group, IdentityProviderException is thrown.
        Parameters:
        userId - the id of the user
        groupId - id of the group
        Returns:
        the operation result object.
        Throws:
        IdentityProviderException
      • createTenantUserMembership

        IdentityOperationResult createTenantUserMembership​(String tenantId,
                                                           String userId)
        Creates a membership relation between a tenant and a user.
        Parameters:
        tenantId - the id of the tenant
        userId - the id of the user
        Returns:
        the operation result object.
      • createTenantGroupMembership

        IdentityOperationResult createTenantGroupMembership​(String tenantId,
                                                            String groupId)
        Creates a membership relation between a tenant and a group.
        Parameters:
        tenantId - the id of the tenant
        groupId - the id of the group
        Returns:
        the operation result object.
      • deleteTenantUserMembership

        IdentityOperationResult deleteTenantUserMembership​(String tenantId,
                                                           String userId)
        Deletes a membership relation between a tenant and a user.
        Parameters:
        tenantId - the id of the tenant
        userId - the id of the user
        Returns:
        the operation result object
      • deleteTenantGroupMembership

        IdentityOperationResult deleteTenantGroupMembership​(String tenantId,
                                                            String groupId)
        Deletes a membership relation between a tenant and a group.
        Parameters:
        tenantId - the id of the tenant
        groupId - the id of the group
        Returns:
        the operation result object.