xgrpc_server

package
v0.0.0-...-fe3505f Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2022 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetSignHeaders

func GetSignHeaders(params map[string]string, secretKey string) map[string]string

func GetSignHeadersFromRequest

func GetSignHeadersFromRequest(cr rpc_request.IConfigRequest, secretKey string) map[string]string

Types

type XgrpcServer

type XgrpcServer struct {
	sync.RWMutex

	ServerSrcChangeSignal chan struct{}
	// contains filtered or unexported fields
}

func NewXgrpcServer

func NewXgrpcServer(serverList []constant.ServerConfig, clientCfg constant.ClientConfig, httpAgent http_agent.IHttpAgent, timeoutMs uint64, endpoint string) (*XgrpcServer, error)

func (*XgrpcServer) GetNextServer

func (server *XgrpcServer) GetNextServer() (constant.ServerConfig, error)

func (*XgrpcServer) GetServerList

func (server *XgrpcServer) GetServerList() []constant.ServerConfig

func (*XgrpcServer) InjectSecurityInfo

func (server *XgrpcServer) InjectSecurityInfo(param map[string]string)

func (*XgrpcServer) InjectSign

func (server *XgrpcServer) InjectSign(request rpc_request.IRequest, param map[string]string, clientConfig constant.ClientConfig)

func (*XgrpcServer) InjectSkAk

func (server *XgrpcServer) InjectSkAk(params map[string]string, clientConfig constant.ClientConfig)

func (*XgrpcServer) ReqApi

func (server *XgrpcServer) ReqApi(api string, params map[string]string, method string) (string, error)

func (*XgrpcServer) ReqConfigApi

func (server *XgrpcServer) ReqConfigApi(api string, params map[string]string, headers map[string]string, method string, timeoutMS uint64) (string, error)

Jump to

Keyboard shortcuts

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