grpctest

package
v0.5.9 Latest Latest
Warning

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

Go to latest
Published: May 5, 2023 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AppServiceTree

func AppServiceTree() (resp []view.RespGrpcAppServiceTreeItem, err error)

func BindProtoToApp

func BindProtoToApp(param view.ReqBindProtoToApp) (err error)

func CreateUseCase

func CreateUseCase(uid uint, param view.ReqCreateGRPCUseCase) (useCaseView view.GrpcUseCaseItem, err error)

func DeleteUseCase

func DeleteUseCase(uid, id uint) (err error)

func Init

func Init(opt Option)

func MethodDetail

func MethodDetail(methodID uint) (resp view.RespDetailGrpcMethod, err error)

func ParseAllProto

func ParseAllProto(basePath, targetPath string) (err error)

func ParseMessage added in v0.4.0

func ParseMessage(descriptor *desc.MessageDescriptor) db.ProtoFields

ParseMessage 解析 Proto 结构描述

func ParseProto

func ParseProto(basePath, proto string)

example:

	proto := /home/www/server/fun-ProtoParser/fun/comment/srv/comment/comment.proto
 ParseProto(proto)

func Proto

func Proto() (resp view.RespListGRPCProto, err error)

func ProtoAbsPath added in v0.4.0

func ProtoAbsPath(filename string) string

func RequestHistoryItem

func RequestHistoryItem(id uint) (history view.GrpcHistoryItem, err error)

func RequestHistoryList

func RequestHistoryList(param view.ReqGrpcHistoryList, uid uint) (resp view.RespGrpcHistoryList, err error)

func SendRequestCallGRPC

func SendRequestCallGRPC(req view.MakeGrpcRequest) (response view.GrpcResponse, err error)

func SendSingleRequest added in v0.4.0

func SendSingleRequest(req view.MakeGrpcRequest) (result xtest.TestResult, err error)

func Services added in v0.4.0

func Services(appName string) (services []view.RespGrpcServiceMethodItem, err error)

func UpdateUseCase

func UpdateUseCase(uid uint, param view.ReqUpdateGRPCUseCase) (useCaseView view.GrpcUseCaseItem, err error)

func UseCaseDetail

func UseCaseDetail(id uint) (resp view.GrpcUseCaseDetail, err error)

func UseCases

func UseCases(uid uint, param view.ReqListGRPCUseCases) (resp []view.RespListMethodUseCaseItem, err error)

func UserMakeRequest

func UserMakeRequest(uid uint, req view.MakeGrpcRequest) (response view.GrpcResponse, err error)

Types

type Option

type Option struct {
	Enabled  bool
	DB       *gorm.DB
	ProtoDir string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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