Skip to content

Commit

Permalink
Remove duplicate recovery interceptor (flyteorg#5870)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sovietaced authored Oct 23, 2024
1 parent e4d29f8 commit 88aac68
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions flyteadmin/pkg/server/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import (
"github.com/gorilla/handlers"
grpcmiddleware "github.com/grpc-ecosystem/go-grpc-middleware"
grpcauth "github.com/grpc-ecosystem/go-grpc-middleware/auth"
grpcrecovery "github.com/grpc-ecosystem/go-grpc-middleware/recovery"
grpcprometheus "github.com/grpc-ecosystem/go-grpc-prometheus"
"github.com/grpc-ecosystem/grpc-gateway/v2/runtime"
"github.com/pkg/errors"
Expand Down Expand Up @@ -111,7 +110,6 @@ func newGRPCServer(ctx context.Context, pluginRegistry *plugins.Registry, cfg *c
chainedUnaryInterceptors = grpcmiddleware.ChainUnaryServer(
// recovery interceptor should always be first in order to handle any panics in the middleware or server
recoveryInterceptor.UnaryServerInterceptor(),
grpcrecovery.UnaryServerInterceptor(),
grpcprometheus.UnaryServerInterceptor,
otelUnaryServerInterceptor,
auth.GetAuthenticationCustomMetadataInterceptor(authCtx),
Expand All @@ -136,7 +134,6 @@ func newGRPCServer(ctx context.Context, pluginRegistry *plugins.Registry, cfg *c
)

serverOpts := []grpc.ServerOption{
// recovery interceptor should always be first in order to handle any panics in the middleware or server
grpc.StreamInterceptor(chainedStreamInterceptors),
grpc.UnaryInterceptor(chainedUnaryInterceptors),
}
Expand Down

0 comments on commit 88aac68

Please sign in to comment.