proxy

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 31, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewProxyCallPlugin added in v0.2.1

func NewProxyCallPlugin(fn func(*Label) CallForwarder) drpc.Plugin

NewProxyCallPlugin 创建call方法的代理插件

func NewProxyPlugin added in v0.2.1

func NewProxyPlugin(fn func(*Label) Forwarder) drpc.Plugin

NewProxyPlugin 创建代理插件,支持call方法和push方法

func NewProxyPushPlugin added in v0.2.1

func NewProxyPushPlugin(fn func(*Label) PushForwarder) drpc.Plugin

NewProxyPushPlugin 创建push方法的代理插件

Types

type CallForwarder

type CallForwarder interface {
	Call(uri string, arg interface{}, result interface{}, setting ...message.MsgSetting) drpc.CallCmd
}

type Forwarder

type Forwarder interface {
	CallForwarder
	PushForwarder
}

type Label

type Label struct {
	SessionID     string
	RealIP        string
	ServiceMethod string
}

type PushForwarder

type PushForwarder interface {
	Push(uri string, arg interface{}, setting ...message.MsgSetting) *drpc.Status
}

Jump to

Keyboard shortcuts

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