Documentation ¶
Index ¶
- type Service
- func (s *Service) AuthInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, ...) (interface{}, error)
- func (s *Service) AuthenticateClient(token string) (*authpb.User, error)
- func (s *Service) Start()
- func (s *Service) StartGRPCServer(serv *grpc.Server) error
- func (s *Service) StartRESTServer(serv *http.Server) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Service ¶
type Service struct { Config *config.ServiceConfig AuthRPCs []string RPCBasePath string RegisterGrpcServer func(*grpc.Server, *zlog.ZwitLogger) RegisterRestServer func(context.Context, *runtime.ServeMux, string, []grpc.DialOption) error UsersServiceClient userspb.UsersServiceClient PostsServiceClient postspb.PostsServiceClient AuthServiceClient authpb.AuthServiceClient SwaggerFile string Log *zlog.ZwitLogger }
func (*Service) AuthInterceptor ¶
func (s *Service) AuthInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)
func (*Service) AuthenticateClient ¶
Click to show internal directories.
Click to hide internal directories.