From 3d489781a0feac8b21dfc0f625c6a82f0933c3df Mon Sep 17 00:00:00 2001 From: Niels de Vos Date: Tue, 9 May 2023 09:54:10 +0200 Subject: [PATCH] rebase: `grpc_middleware.WithUnaryServerChain` is deprecated golangci-lint reports that `grpc_middleware.WithUnaryServerChain` is deprecated and `google.golang.org/grpc.ChainUnaryInterceptor` should be used instead. Signed-off-by: Niels de Vos --- internal/csi-common/utils.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/csi-common/utils.go b/internal/csi-common/utils.go index a2eaa741f..a2bb4ab86 100644 --- a/internal/csi-common/utils.go +++ b/internal/csi-common/utils.go @@ -118,7 +118,7 @@ func NewMiddlewareServerOption(withMetrics bool) grpc.ServerOption { middleWare = append(middleWare, grpc_prometheus.UnaryServerInterceptor) } - return grpc_middleware.WithUnaryServerChain(middleWare...) + return grpc.UnaryInterceptor(grpc_middleware.ChainUnaryServer(middleWare...)) } func getReqID(req interface{}) string {