middleware

package
v0.0.0-...-d6e0c60 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2025 License: MIT Imports: 8 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Log *zap.Logger
)

Functions

func KeepAliveServerParams

func KeepAliveServerParams() keepalive.ServerParameters

func KeepaliveEnforcementPolicy

func KeepaliveEnforcementPolicy() keepalive.EnforcementPolicy

Types

type ClientInterceptor

type ClientInterceptor struct {
	Unary  grpc.UnaryClientInterceptor
	Stream grpc.StreamClientInterceptor
}

func (*ClientInterceptor) UnaryClientInterceptor

func (cl *ClientInterceptor) UnaryClientInterceptor(
	ctx context.Context,
	method string,
	req interface{},
	reply interface{},
	cc *grpc.ClientConn,
	invoker grpc.UnaryInvoker,
	opts ...grpc.CallOption,
) error

type ServerInterceptor

type ServerInterceptor struct {
	Unary  grpc.UnaryServerInterceptor
	Stream grpc.StreamServerInterceptor
}

func (*ServerInterceptor) UnaryServerInterceptor

func (si *ServerInterceptor) UnaryServerInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)

UnaryServerInterceptor is a middleware for gRPC server requests.

Jump to

Keyboard shortcuts

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