Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrMethodPathNotFound   = errors.New("route: methodPath not found")
	ErrClientExists         = errors.New("route: client exists")
	ErrAddressNotFound      = errors.New("route: address not fount")
	ErrGprcServerConnFailed = errors.New("route: connection to grpc server failed")
)

Functions

func Init

func Init(localPeer core.LocalPeer, cnf *config.RouteConfig, twheel *tw.TimingWheel) core.Router

    初始化本地route peer 本地cluster 编号

    func Register

    func Register(mps []core.MethodPath, pr core.PeerRouter, address string) error

    func RouteIn

    func RouteIn(mp core.MethodPath, id string, request proto.Message) (response proto.Message, err error)

    Types

    This section is empty.