diff --git a/cmd/api/main.go b/cmd/api/main.go index 5ba22fbd3..ef6803b8f 100644 --- a/cmd/api/main.go +++ b/cmd/api/main.go @@ -39,7 +39,6 @@ import ( "go.uber.org/zap/zapcore" "github.com/golang-jwt/jwt/v4" - grpc_middleware "github.com/grpc-ecosystem/go-grpc-middleware" grpc_auth "github.com/grpc-ecosystem/go-grpc-middleware/auth" grpc_zap "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap" "github.com/grpc-ecosystem/go-grpc-middleware/logging/zap/ctxzap" @@ -156,7 +155,7 @@ func main() { gs := grpc.NewServer( grpc.Creds(creds), - grpc_middleware.WithUnaryServerChain( + grpc.ChainUnaryInterceptor( // The grpc_ctxtags context updater should be before everything else grpc_ctxtags.UnaryServerInterceptor(grpc_ctxtags.WithFieldExtractor(grpc_ctxtags.CodeGenRequestFieldExtractor)), grpc_zap.UnaryServerInterceptor(grpcLogger, zapOpts...), @@ -164,7 +163,7 @@ func main() { prometheus.UnaryServerInterceptor, recovery.UnaryServerInterceptor(recovery.WithRecoveryHandler(recoveryHandler)), ), - grpc_middleware.WithStreamServerChain( + grpc.ChainStreamInterceptor( // The grpc_ctxtags context updater should be before everything else grpc_ctxtags.StreamServerInterceptor(grpc_ctxtags.WithFieldExtractor(grpc_ctxtags.CodeGenRequestFieldExtractor)), grpc_zap.StreamServerInterceptor(grpcLogger, zapOpts...),