grpcs

package
v0.2.10-107 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2024 License: Apache-2.0 Imports: 61 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() lava.Service

func NewInner

func NewInner(handlers []lava.GrpcRouter, dixMiddlewares []lava.Middleware, metric metrics.Metric, log log.Logger) *lava.InnerServer

NewInner grpc 服务内部通信

func NewMux

func NewMux(handlers []lava.GrpcRouter, dixMiddlewares []lava.Middleware, metric metrics.Metric, log log.Logger) *gateway.Mux

func RegParser

func RegParser(customType interface{}, converter func(string) reflect.Value)

Types

type Config

type Config struct {
	EnablePrintRoutes bool                 `yaml:"enable_print_routes"`
	BaseUrl           string               `yaml:"base_url"`
	GrpcConfig        *grpc_builder.Config `yaml:"grpc_config"`
	EnableCors        bool                 `yaml:"enable_cors"`
	GrpcPort          *int                 `yaml:"grpc_port"`
	HttpPort          *int                 `yaml:"http_port"`
}

type DefaultQueryParser

type DefaultQueryParser struct{}

func (*DefaultQueryParser) Parse

func (*DefaultQueryParser) Parse(msg proto.Message, values url.Values, filter *utilities.DoubleArray) error

Parse populates "values" into "msg". A value is ignored if its key starts with one of the elements in "filter".

type GrpcServerConfigLoader

type GrpcServerConfigLoader struct {
	GrpcServer *Config `yaml:"grpc_server"`
}

Jump to

Keyboard shortcuts

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