Skip to content

Commit

Permalink
Enable SyncerTunnel featuregate by default
Browse files Browse the repository at this point in the history
  • Loading branch information
jmprusi committed Mar 8, 2023
1 parent 85793f9 commit cac4323
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 9 deletions.
2 changes: 1 addition & 1 deletion pkg/features/kcp_features.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ func (f *kcpFeatureGate) Type() string {
// here. The features will be available throughout Kubernetes binaries.
var defaultGenericControlPlaneFeatureGates = map[featuregate.Feature]featuregate.FeatureSpec{
LocationAPI: {Default: true, PreRelease: featuregate.Alpha},
SyncerTunnel: {Default: false, PreRelease: featuregate.Alpha},
SyncerTunnel: {Default: true, PreRelease: featuregate.Alpha},

// inherited features from generic apiserver, relisted here to get a conflict if it is changed
// unintentionally on either side:
Expand Down
9 changes: 1 addition & 8 deletions test/e2e/syncer/tunnels_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,10 @@ import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/types"
"k8s.io/apimachinery/pkg/util/wait"
utilfeature "k8s.io/apiserver/pkg/util/feature"
"k8s.io/client-go/kubernetes"
featuregatetesting "k8s.io/component-base/featuregate/testing"

workloadv1alpha1 "github.com/kcp-dev/kcp/pkg/apis/workload/v1alpha1"
kcpclientset "github.com/kcp-dev/kcp/pkg/client/clientset/versioned/cluster"
"github.com/kcp-dev/kcp/pkg/features"
"github.com/kcp-dev/kcp/pkg/syncer/shared"
"github.com/kcp-dev/kcp/test/e2e/framework"
)
Expand All @@ -54,8 +51,6 @@ func TestSyncerTunnel(t *testing.T) {
t.Skip("Test requires a pcluster")
}

defer featuregatetesting.SetFeatureGateDuringTest(t, utilfeature.DefaultFeatureGate, features.SyncerTunnel, true)()

tokenAuthFile := framework.WriteTokenAuthFile(t)
upstreamServer := framework.PrivateKcpServer(t, framework.WithCustomArguments(framework.TestServerArgsWithTokenAuthFile(tokenAuthFile)...))
t.Log("Creating an organization")
Expand Down Expand Up @@ -287,12 +282,10 @@ func TestSyncerTunnelFilter(t *testing.T) {
t.Parallel()
framework.Suite(t, "transparent-multi-cluster")

defer featuregatetesting.SetFeatureGateDuringTest(t, utilfeature.DefaultFeatureGate, features.SyncerTunnel, true)()

ctx, cancelFunc := context.WithCancel(context.Background())
t.Cleanup(cancelFunc)

kcpServer := framework.PrivateKcpServer(t)
kcpServer := framework.SharedKcpServer(t)
orgPath, _ := framework.NewOrganizationFixture(t, kcpServer, framework.TODO_WithoutMultiShardSupport())
locationPath, locationWs := framework.NewWorkspaceFixture(t, kcpServer, orgPath, framework.TODO_WithoutMultiShardSupport())
locationWsName := logicalcluster.Name(locationWs.Spec.Cluster)
Expand Down

0 comments on commit cac4323

Please sign in to comment.