Documentation ¶
Index ¶
- func InstallPanicHandler(handler PanicHandler)
- func StreamPanicHandler(srv interface{}, stream grpc.ServerStream, info *grpc.StreamServerInfo, ...) (err error)
- func UnaryPanicHandler(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, ...) (resp interface{}, err error)
- type PanicHandler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InstallPanicHandler ¶
func InstallPanicHandler(handler PanicHandler)
InstallPanicHandler installs additional crash handles for dealing with a panic
func StreamPanicHandler ¶
func StreamPanicHandler(srv interface{}, stream grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) (err error)
StreamPanicHandler handles stream panics
func UnaryPanicHandler ¶
func UnaryPanicHandler(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (resp interface{}, err error)
UnaryPanicHandler handles request-response panics
Types ¶
type PanicHandler ¶
type PanicHandler func(methodName string, error interface{})
PanicHandler is a handler that will be called on a grpc panic
Click to show internal directories.
Click to hide internal directories.