gateway

package
v0.6.9 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IncomingHeaderMatcher

func IncomingHeaderMatcher(key string) (string, bool)

IncomingHeaderMatcher will rewrite HTTP header keys into gRPC header keys. All remaining headers are treated with the default policy. The header comparison is case-insensitive.

Types

type Gateway

type Gateway interface {
	HttpMux() *runtime.ServeMux
	GrpcDialOpts() []grpc.DialOption
	Context() context.Context
	DialOptsWithUnaryInterceptors(interceptors ...grpc.UnaryClientInterceptor) []grpc.DialOption
}

func NewGateway

func NewGateway(ctx context.Context, options ...Option) Gateway

type Option added in v0.4.6

type Option func(*Options)

func ResponseInterceptor added in v0.4.6

func ResponseInterceptor(interceptor ResponseInterceptorFunc) Option

type Options added in v0.4.6

type Options struct {
	ResponseInterceptor ResponseInterceptorFunc
}

type ResponseInterceptorFunc added in v0.4.6

type ResponseInterceptorFunc func(context.Context, http.ResponseWriter, proto.Message) error

Jump to

Keyboard shortcuts

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