grpcmw

package
v0.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 16, 2025 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrGRPCNotEnabled = ewrap.New("grpc middleware requires build tag 'grpc'")

ErrGRPCNotEnabled indicates that the gRPC middleware was built without gRPC support.

Functions

func UnaryServerInterceptor

func UnaryServerInterceptor(opts ...Option) grpc.UnaryServerInterceptor

UnaryServerInterceptor returns a stub interceptor when the gRPC build tag is not provided.

Types

type Option

type Option func(*options)

Option defines a configuration option for the gRPC middleware.

func WithRequestKey

func WithRequestKey(name string) Option

WithRequestKey customizes the metadata key used to populate the request identifier.

func WithTraceKey

func WithTraceKey(name string) Option

WithTraceKey customizes the metadata key used to populate the trace identifier.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL