Documentation ¶
Index ¶
- func ClientStreamInterceptor(ctx context.Context, desc *grpc.StreamDesc, cc *grpc.ClientConn, method string, ...) (grpc.ClientStream, error)
- func ClientUnaryInterceptor(ctx context.Context, method string, req, reply interface{}, ...) error
- type Server
- type ServerOption
- func Address(addr string) ServerOption
- func GrpcDefaultUnaryServerInterceptor() ServerOption
- func GrpcKeepAlive(kp keepalive.ServerParameters) ServerOption
- func GrpcOpts(opts ...grpc.ServerOption) ServerOption
- func GrpcStreamServerInterceptor(interceptors ...grpc.StreamServerInterceptor) ServerOption
- func GrpcUnaryServerInterceptor(interceptors ...grpc.UnaryServerInterceptor) ServerOption
- func HealthCheck() ServerOption
- func Logger(logger *logrus.Entry) ServerOption
- func Network(network string) ServerOption
- func Prometheus(enableHandlingTimeHistogram bool, prometheusAddr string) ServerOption
- func Reflection() ServerOption
- func Timeout(timeout time.Duration) ServerOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ClientStreamInterceptor ¶
func ClientStreamInterceptor(ctx context.Context, desc *grpc.StreamDesc, cc *grpc.ClientConn, method string, streamer grpc.Streamer, opts ...grpc.CallOption) (grpc.ClientStream, error)
func ClientUnaryInterceptor ¶
func ClientUnaryInterceptor(ctx context.Context, method string, req, reply interface{}, cc *grpc.ClientConn, invoker grpc.UnaryInvoker, opts ...grpc.CallOption) error
Types ¶
type ServerOption ¶
type ServerOption func(o *Server)
func GrpcDefaultUnaryServerInterceptor ¶
func GrpcDefaultUnaryServerInterceptor() ServerOption
func GrpcKeepAlive ¶
func GrpcKeepAlive(kp keepalive.ServerParameters) ServerOption
func GrpcOpts ¶
func GrpcOpts(opts ...grpc.ServerOption) ServerOption
func GrpcStreamServerInterceptor ¶
func GrpcStreamServerInterceptor(interceptors ...grpc.StreamServerInterceptor) ServerOption
func GrpcUnaryServerInterceptor ¶
func GrpcUnaryServerInterceptor(interceptors ...grpc.UnaryServerInterceptor) ServerOption
func HealthCheck ¶
func HealthCheck() ServerOption
func Logger ¶
func Logger(logger *logrus.Entry) ServerOption
func Prometheus ¶
func Prometheus(enableHandlingTimeHistogram bool, prometheusAddr string) ServerOption
func Reflection ¶
func Reflection() ServerOption
Click to show internal directories.
Click to hide internal directories.