From d40a17c321cfe736fc01bdfeb8b4aa25a86af1bd Mon Sep 17 00:00:00 2001 From: Paul Okstad Date: Thu, 22 Aug 2019 15:03:13 -0700 Subject: Disable invalidator and info-ref cache feature flags --- internal/middleware/cache/cache.go | 9 --------- internal/service/smarthttp/cache.go | 4 +--- 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/internal/middleware/cache/cache.go b/internal/middleware/cache/cache.go index 2a65c6447..2f931bdda 100644 --- a/internal/middleware/cache/cache.go +++ b/internal/middleware/cache/cache.go @@ -8,7 +8,6 @@ import ( "github.com/golang/protobuf/proto" "github.com/sirupsen/logrus" diskcache "gitlab.com/gitlab-org/gitaly/internal/cache" - "gitlab.com/gitlab-org/gitaly/internal/metadata/featureflag" "gitlab.com/gitlab-org/gitaly/internal/praefect/protoregistry" "gitlab.com/gitlab-org/gitaly/proto/go/gitalypb" "google.golang.org/grpc" @@ -36,10 +35,6 @@ func methodErrLogger(method string) func(error) { // repository in a gRPC stream based RPC func StreamInvalidator(ci Invalidator, reg *protoregistry.Registry) grpc.StreamServerInterceptor { return func(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) error { - if !featureflag.IsEnabled(ss.Context(), FeatureFlag) { - return handler(srv, ss) - } - errLogger := methodErrLogger(info.FullMethod) mInfo, err := reg.LookupMethod(info.FullMethod) @@ -63,10 +58,6 @@ func StreamInvalidator(ci Invalidator, reg *protoregistry.Registry) grpc.StreamS // repository in a gRPC unary RPC func UnaryInvalidator(ci Invalidator, reg *protoregistry.Registry) grpc.UnaryServerInterceptor { return func(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (resp interface{}, err error) { - if !featureflag.IsEnabled(ctx, FeatureFlag) { - return handler(ctx, req) - } - errLogger := methodErrLogger(info.FullMethod) mInfo, err := reg.LookupMethod(info.FullMethod) diff --git a/internal/service/smarthttp/cache.go b/internal/service/smarthttp/cache.go index 8cb864bdd..247e335b2 100644 --- a/internal/service/smarthttp/cache.go +++ b/internal/service/smarthttp/cache.go @@ -9,7 +9,6 @@ import ( "github.com/prometheus/client_golang/prometheus" log "github.com/sirupsen/logrus" "gitlab.com/gitlab-org/gitaly/internal/cache" - "gitlab.com/gitlab-org/gitaly/internal/metadata/featureflag" "gitlab.com/gitlab-org/gitaly/proto/go/gitalypb" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" @@ -49,8 +48,7 @@ func init() { const UploadPackCacheFeatureFlagKey = "inforef-uploadpack-cache" func tryCache(ctx context.Context, in *gitalypb.InfoRefsRequest, w io.Writer, missFn func(io.Writer) error) error { - if !featureflag.IsEnabled(ctx, UploadPackCacheFeatureFlagKey) || - len(in.GetGitConfigOptions()) > 0 || + if len(in.GetGitConfigOptions()) > 0 || len(in.GetGitProtocol()) > 0 { return missFn(w) } -- cgit v1.2.3