node

package
v1.2.3 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2022 License: LGPL-3.0 Imports: 14 Imported by: 0

Documentation

Overview

Package node 文件包括本地服务(服务节点)的所有注册服务和远程调用本地服务的相应处理方法

Index

Constants

View Source
const RpcExecuteFuncName = "Execute"

RpcExecuteFuncName 执行服务

View Source
const RpcGetInfoFuncName = "GetInfo"

RpcGetInfoFuncName 获取节点信息

Variables

This section is empty.

Functions

func GetLocalNodeInfo added in v1.0.5

func GetLocalNodeInfo() *data.NodeInfo

GetLocalNodeInfo 获取本地节点信息

func GetNodeConfig

func GetNodeConfig() *data.ESConfig

func InitESConfig

func InitESConfig(configFile ...string) error

InitESConfig 初始化rpc服务端

func Reg

func Reg(servicePath string, serviceInstance interface{})

Reg 注册本地服务

func StartNodeServer

func StartNodeServer()

Types

type ESNode

type ESNode int

ESNode rpcx暴露的服务

func (*ESNode) Execute

func (*ESNode) Execute(ctx context.Context, request *data.Request, result *data.Result) error

Execute 执行服务

func (*ESNode) GetInfo

func (*ESNode) GetInfo(ctx context.Context, request *data.Request, result *data.Result) error

GetInfo 获取信息

Jump to

Keyboard shortcuts

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