rpcserver

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Kaep = keepalive.EnforcementPolicy{
	MinTime:             5 * time.Second,
	PermitWithoutStream: true,
}
View Source
var Kasp = keepalive.ServerParameters{
	MaxConnectionIdle:     30 * time.Second,
	MaxConnectionAge:      30 * time.Second,
	MaxConnectionAgeGrace: 5 * time.Second,
	Time:                  5 * time.Second,
	Timeout:               3 * time.Second,
}

resource --> driver是短连接,以下参数可有可无

Functions

This section is empty.

Types

type RPCServer

type RPCServer struct {
	// contains filtered or unexported fields
}

func NewRPCServer

func NewRPCServer(
	ctx context.Context,
	cancel context.CancelFunc,
	registerFunc RegisterFunc,
	rpcConfig config.RPCConfig,
	lc commons.TedgeLogger) (*RPCServer, error)

func (*RPCServer) Serve

func (rpcSrv *RPCServer) Serve() error

type RegisterFunc

type RegisterFunc func(serve *grpc.Server)

Jump to

Keyboard shortcuts

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