Skip to content

Commit

Permalink
chore: graduate feature gate FillIDs to Beta and set to true by default
Browse files Browse the repository at this point in the history
  • Loading branch information
programmer04 committed Sep 27, 2023
1 parent 95b0447 commit c99eafd
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 20 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/_integration_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,10 @@ jobs:
router-flavor: "expressions"
- name: dbless-fill-ids
test: dbless
feature_gates: "GatewayAlpha=true,FillIDs=true"
feature_gates: "GatewayAlpha=true"
- name: postgres-fill-ids
test: postgres
feature_gates: "GatewayAlpha=true,FillIDs=true"
feature_gates: "GatewayAlpha=true"
- name: dbless-rewrite-uris
test: dbless
feature_gates: "GatewayAlpha=true,RewriteURIs=true"
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,11 @@ Adding a new version? You'll need three changes:
- No more "log.SetLogger(...) was never called..." log entry during shutdown of KIC
[#4738](https://github.com/Kong/kubernetes-ingress-controller/pull/4738)

### Added

- The `FillIDs` feature gate is now enabled by default.


## 2.12.0

> Release date: 2023-09-25
Expand Down
1 change: 1 addition & 0 deletions FEATURE_GATES.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ Features that reach GA and over time become stable will be removed from this tab
| CombinedServices | `false` | Alpha | 2.10.0 | 3.0.0 |
| CombinedServices | `true` | Beta | 2.11.0 | 3.0.0 |
| FillIDs | `false` | Alpha | 2.10.0 | 3.0.0 |
| FillIDs | `true` | Beta | 3.0.0 | TBD |
| RewriteURIs | `false` | Alpha | 2.12.0 | TBD |

**NOTE**: The `Gateway` feature gate refers to [Gateway
Expand Down
6 changes: 3 additions & 3 deletions internal/dataplane/parser/parser_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5080,12 +5080,12 @@ func TestNewFeatureFlags(t *testing.T) {
},
},
{
name: "fill ids enabled",
name: "fill ids disabled",
featureGates: map[string]bool{
featuregates.FillIDsFeature: true,
featuregates.FillIDsFeature: false,
},
expectedFeatureFlags: FeatureFlags{
FillIDs: true,
FillIDs: false,
},
},
}
Expand Down
2 changes: 1 addition & 1 deletion internal/manager/featuregates/feature_gates.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ func GetFeatureGatesDefaults() map[string]bool {
GatewayAlphaFeature: false,
CombinedRoutesFeature: true,
ExpressionRoutesFeature: false,
FillIDsFeature: false,
FillIDsFeature: true,
RewriteURIsFeature: false,
}
}
13 changes: 0 additions & 13 deletions test/e2e/upgrade_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,19 +42,6 @@ func TestDeployAndUpgradeAllInOnePostgres(t *testing.T) {
})
}

func TestDeployAndUpgradeAllInOnePostgres_FeatureGates(t *testing.T) {
testManifestsUpgrade(t, manifestsUpgradeTestParams{
fromManifestURL: fmt.Sprintf(postgresURLTemplate, upgradeTestFromTag),
toManifestPath: postgresPath,
beforeUpgradeHook: postgresBeforeUpgradeHook,
// We want to test that nothing breaks when enabling FillIDs feature gate to prevent regressions like
// https://github.com/Kong/kubernetes-ingress-controller/issues/4025.
// In 2.10.0 this is disabled by default, so we need a separate test for this.
// TODO: remove this test when FillIDs is enabled by default.
controllerFeatureGates: "FillIDs=true",
})
}

func postgresBeforeUpgradeHook(ctx context.Context, t *testing.T, env environments.Environment) {
// Injecting a beforeUpgradeHook to delete the old migrations job before the upgrade. This is necessary because it's
// not allowed to modify the existing job's spec.
Expand Down
2 changes: 1 addition & 1 deletion test/envtest/telemetry_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ func verifyTelemetryReport(t *testing.T, k8sVersion *version.Info, report string
"db=off;"+
"feature-combinedroutes=true;"+
"feature-expressionroutes=false;"+
"feature-fillids=false;"+
"feature-fillids=true;"+
"feature-gateway-service-discovery=false;"+
"feature-gateway=false;"+
"feature-gatewayalpha=false;"+
Expand Down

0 comments on commit c99eafd

Please sign in to comment.