grpc

package
v1.34.0 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2023 License: Unlicense Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewServer

func NewServer(params ServerParams) v1.ServiceServer

NewServer for gRPC.

func Register

func Register(params RegisterParams) error

Register server.

Types

type RegisterParams

type RegisterParams struct {
	fx.In

	Lifecycle  fx.Lifecycle
	GRPCServer *grpc.Server
	HTTPServer *http.Server
	GRPCConfig *grpc.Config
	Logger     *zap.Logger
	Tracer     tracer.Tracer
	Metrics    *prometheus.ClientCollector
	Server     v1.ServiceServer
}

RegisterParams for gRPC.

type Server

type Server struct {
	v1.UnimplementedServiceServer
	// contains filtered or unexported fields
}

Server for gRPC.

func (*Server) GenerateAccessToken added in v1.5.0

GenerateAccessToken for gRPC.

func (*Server) GenerateKey added in v1.4.0

func (s *Server) GenerateKey(ctx context.Context, req *v1.GenerateKeyRequest) (*v1.GenerateKeyResponse, error)

GenerateKey for gRPC.

func (*Server) GeneratePassword

func (s *Server) GeneratePassword(ctx context.Context, req *v1.GeneratePasswordRequest) (*v1.GeneratePasswordResponse, error)

GeneratePassword for gRPC.

func (*Server) GenerateServiceToken added in v1.7.0

GenerateServiceToken for gRPC.

func (*Server) GetPublicKey added in v1.10.0

func (s *Server) GetPublicKey(ctx context.Context, req *v1.GetPublicKeyRequest) (*v1.GetPublicKeyResponse, error)

GetPublicKey from kind.

func (*Server) VerifyServiceToken added in v1.12.0

VerifyServiceToken for gRPC.

type ServerParams added in v1.10.4

type ServerParams struct {
	fx.In

	Config           *config.Config
	Key              *key.Config
	RSA              *key.RSA
	KeyGenerator     *key.Generator
	ServiceGenerator *service.Service
	PrivateKey       ed25519.PrivateKey
	Secure           *password.Secure
	Enforcer         *casbin.Enforcer
	Cache            *ristretto.Cache
}

ServerParams for gRPC.

Jump to

Keyboard shortcuts

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