grpc

package
v1.0.5 Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2023 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 3 more Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetV2ResponseCode

func GetV2ResponseCode(rsp interface{}) (uint32, bool)

GetV2ResponseCode 获取返回码

Types

type RateLimitServiceV2

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

RateLimitServiceV2 限流Server:v2接口

func (*RateLimitServiceV2) Service

Service 限流KEY初始化

func (*RateLimitServiceV2) TimeAdjust

TimeAdjust 获取时间戳

type Server

type Server struct {
	IP   string
	Port uint32
	// contains filtered or unexported fields
}

Server grpc server

func (*Server) GetPort

func (g *Server) GetPort() uint32

GetPort 返回port

func (*Server) GetProtocol

func (g *Server) GetProtocol() string

GetProtocol 返回协议

func (*Server) Initialize

func (g *Server) Initialize(option map[string]interface{}) error

Initialize 初始化函数

func (*Server) Run

func (g *Server) Run(errCh chan error)

Run 入口函数

func (*Server) Stop

func (g *Server) Stop()

Stop 停止

Jump to

Keyboard shortcuts

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