grpc

package
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 18, 2018 License: AGPL-3.0 Imports: 22 Imported by: 0

Documentation

Overview

Package grpc provides persistence layer for CRUD-ing roles

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitRoles

func InitRoles(ctx context.Context) error

func InsertActionsAcls

func InsertActionsAcls(ctx context.Context, roleId string, repoScope string, actions map[string][]string) error

Types

type Cleaner

type Cleaner struct {
	resources.PoliciesCleaner
	// contains filtered or unexported fields
}

func NewCleaner

func NewCleaner(handler *Handler, dao dao.DAO) *Cleaner

func (*Cleaner) Handle

func (c *Cleaner) Handle(ctx context.Context, msg *idm.ChangeEvent) error

type Handler

type Handler struct{}

Handler definition

func (*Handler) CreateRole

func (h *Handler) CreateRole(ctx context.Context, req *idm.CreateRoleRequest, resp *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, response *idm.DeleteRoleResponse) error

DeleteRole from database

func (*Handler) SearchRole

func (h *Handler) SearchRole(ctx context.Context, request *idm.SearchRoleRequest, response idm.RoleService_SearchRoleStream) error

SearchRole in database

func (*Handler) StreamRole

func (h *Handler) StreamRole(ctx context.Context, streamer idm.RoleService_StreamRoleStream) error

StreamRole from database

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL