Documentation ¶
Index ¶
- func StreamCtxHandleGRPC() grpc.StreamClientInterceptor
- func UnaryCtxHandleGRPC() grpc.UnaryClientInterceptor
- type AppServerInterceptor
- func (i *AppServerInterceptor) Logger(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, ...) (interface{}, error)
- func (i *AppServerInterceptor) Metadata(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, ...) (interface{}, error)
- func (i *AppServerInterceptor) Recovery(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, ...) (resp interface{}, err error)
- func (i *AppServerInterceptor) RecoveryStream(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, ...) error
- func (i *AppServerInterceptor) StreamLogger(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, ...) error
- func (i *AppServerInterceptor) StreamMetadata(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, ...) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func StreamCtxHandleGRPC ¶
func StreamCtxHandleGRPC() grpc.StreamClientInterceptor
func UnaryCtxHandleGRPC ¶
func UnaryCtxHandleGRPC() grpc.UnaryClientInterceptor
Types ¶
type AppServerInterceptor ¶ added in v1.5.11
type AppServerInterceptor struct {
// contains filtered or unexported fields
}
func NewAppServerInterceptor ¶ added in v1.5.11
func NewAppServerInterceptor(debug bool, accessLogger, errLogger log.LoggerContextIface) *AppServerInterceptor
func (*AppServerInterceptor) Logger ¶ added in v1.5.11
func (i *AppServerInterceptor) Logger(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)
Logger add app info in ctx.
func (*AppServerInterceptor) Metadata ¶ added in v1.5.11
func (i *AppServerInterceptor) Metadata(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)
func (*AppServerInterceptor) Recovery ¶ added in v1.5.11
func (i *AppServerInterceptor) Recovery(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (resp interface{}, err error)
Recovery recovers GRPC panic.
func (*AppServerInterceptor) RecoveryStream ¶ added in v1.5.11
func (i *AppServerInterceptor) RecoveryStream(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) error
RecoveryStream is experimental function
func (*AppServerInterceptor) StreamLogger ¶ added in v1.5.11
func (i *AppServerInterceptor) StreamLogger(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) error
StreamLogger is experimental function
func (*AppServerInterceptor) StreamMetadata ¶ added in v1.5.11
func (i *AppServerInterceptor) StreamMetadata(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) error
Click to show internal directories.
Click to hide internal directories.