Documentation ¶
Overview ¶
Package grpc provides persistence layer for CRUD-ing roles
Index ¶
- Constants
- func InitRoles(ctx context.Context) error
- func NewHandler(ctx context.Context, dao role.DAO) idm.NamedRoleServiceServer
- func UpgradeTo12(ctx context.Context) error
- type Cleaner
- type Handler
- func (h *Handler) CountRole(ctx context.Context, request *idm.SearchRoleRequest) (*idm.CountRoleResponse, error)
- func (h *Handler) CreateRole(ctx context.Context, req *idm.CreateRoleRequest) (*idm.CreateRoleResponse, error)
- func (h *Handler) DeleteRole(ctx context.Context, req *idm.DeleteRoleRequest) (*idm.DeleteRoleResponse, error)
- func (h *Handler) Name() string
- func (h *Handler) SearchRole(request *idm.SearchRoleRequest, response idm.RoleService_SearchRoleServer) error
- func (h *Handler) StreamRole(streamer idm.RoleService_StreamRoleServer) error
Constants ¶
View Source
const ServiceName = common.ServiceGrpcNamespace_ + common.ServiceRole
Variables ¶
This section is empty.
Functions ¶
func NewHandler ¶
func UpgradeTo12 ¶
Types ¶
type Cleaner ¶
type Cleaner struct { resources.PoliciesCleaner // contains filtered or unexported fields }
func NewCleaner ¶
func NewCleaner(ctx context.Context, handler idm.RoleServiceServer) *Cleaner
type Handler ¶
type Handler struct { idm.UnimplementedRoleServiceServer // contains filtered or unexported fields }
Handler definition
func (*Handler) CountRole ¶
func (h *Handler) CountRole(ctx context.Context, request *idm.SearchRoleRequest) (*idm.CountRoleResponse, error)
CountRole in database
func (*Handler) CreateRole ¶
func (h *Handler) CreateRole(ctx context.Context, req *idm.CreateRoleRequest) (*idm.CreateRoleResponse, error)
CreateRole adds a role and its policies in database
func (*Handler) DeleteRole ¶
func (h *Handler) DeleteRole(ctx context.Context, req *idm.DeleteRoleRequest) (*idm.DeleteRoleResponse, error)
DeleteRole from database
func (*Handler) SearchRole ¶
func (h *Handler) SearchRole(request *idm.SearchRoleRequest, response idm.RoleService_SearchRoleServer) error
SearchRole in database
func (*Handler) StreamRole ¶
func (h *Handler) StreamRole(streamer idm.RoleService_StreamRoleServer) error
StreamRole from database
Click to show internal directories.
Click to hide internal directories.