Documentation ¶
Index ¶
Constants ¶
View Source
const RecoveryExplanation = "Something went wrong"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Interceptor ¶
type Interceptor struct {
// contains filtered or unexported fields
}
func Default ¶
func Default() *Interceptor
func NewInterceptor ¶
func NewInterceptor(h RecoveryHandler) *Interceptor
func (*Interceptor) StreamServerInterceptor ¶
func (i *Interceptor) StreamServerInterceptor() grpc.StreamServerInterceptor
func (*Interceptor) UnaryServerInterceptor ¶
func (i *Interceptor) UnaryServerInterceptor() grpc.UnaryServerInterceptor
AuthUnaryServerInterceptor returns a new unary server interceptor for auth.
type RecoveryHandler ¶
RecoveryHandler is a function that recovers from the panic `p` by returning an `error`. The context can be used to extract request scoped metadata and context values.
type ZapRecoveryHandler ¶
type ZapRecoveryHandler struct {
// contains filtered or unexported fields
}
ZapRecoveryHandler todo
func NewZapRecoveryHandler ¶
func NewZapRecoveryHandler() *ZapRecoveryHandler
func (*ZapRecoveryHandler) Handle ¶
func (h *ZapRecoveryHandler) Handle(ctx context.Context, p interface{}) error
func (*ZapRecoveryHandler) SetLogger ¶
func (h *ZapRecoveryHandler) SetLogger(l logger.Logger) *ZapRecoveryHandler
Click to show internal directories.
Click to hide internal directories.