Documentation
¶
Index ¶
- func ContextTimeout(ctx context.Context)
- func RecoveryInterceptor(p interface{}) error
- func TimeoutInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, ...) (interface{}, error)
- func UnaryInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, ...) (interface{}, error)
- type Server
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RecoveryInterceptor ¶
func RecoveryInterceptor(p interface{}) error
RecoveryInterceptor intercepts panic signals and tries to recover.
func TimeoutInterceptor ¶
func TimeoutInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)
TimeoutInterceptor cancels a request if it does not complete within 'requestTimeout' seconds.
func UnaryInterceptor ¶
func UnaryInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)
UnaryInterceptor ... TODO: example of UnaryInterceptor, use it for auth
Types ¶
Click to show internal directories.
Click to hide internal directories.