grpc

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AuthTokenKey string = "authorization"
)

Variables

This section is empty.

Functions

func NewClient added in v0.0.2

func NewClient(addr string, authToken string) (*grpc.ClientConn, error)

func RunServer added in v0.0.2

func RunServer(addr string, register func(grpcServer *grpc.Server), auth func(token string) bool) error

func ToRpcStruct

func ToRpcStruct(data any) *structpb.Struct

Types

type CommonResp added in v0.0.2

type CommonResp struct {
	Result *structpb.Struct

	GetResult func() *structpb.Struct
}

Jump to

Keyboard shortcuts

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