chore: update DeclarativeValidation featuregate

This commit is contained in:
yongruilin 2025-03-10 22:39:03 +00:00
parent a38d4e53e1
commit 989d68d757
3 changed files with 17 additions and 10 deletions

View File

@ -150,20 +150,27 @@ const (
// Enable usage of Provision of PVCs from snapshots in other namespaces
CrossNamespaceVolumeDataSource featuregate.Feature = "CrossNamespaceVolumeDataSource"
// owner: @thockin
// kep: http://kep.k8s.io/5073:
// owner: @jpbetz @aaron-prindle @yongruilin
// kep: http://kep.k8s.io/5073
// beta: v1.33
//
// Enable declarative validation of APIs, where declared.
// Enables running declarative validation of APIs, where declared. When enabled, APIs with
// declarative validation rules will validate objects using the generated
// declarative validation code and compare the results to the regular imperative validation.
// See DeclarativeValidationTakeover for more.
DeclarativeValidation featuregate.Feature = "DeclarativeValidation"
// owner: @thockin
// kep: http://kep.k8s.io/5073:
// owner: @jpbetz @aaron-prindle @yongruilin
// kep: http://kep.k8s.io/5073
// beta: v1.33
//
// Enable declarative_validation_mismatch metric which outputs # of mismatch occurrences between
// hand-written and declarative validation rules.
DeclarativeValidationMismatchMetric featuregate.Feature = "DeclarativeValidationMismatchMetric"
// When enabled, declarative validation errors are returned directly to the caller,
// replacing hand-written validation errors for rules that have declarative implementations.
// When disabled, hand-written validation errors are always returned, effectively putting
// declarative validation in a "shadow mode" that monitors but does not affect API responses.
// Note: Although declarative validation aims for functional equivalence with hand-written validation,
// the exact number, format, and content of error messages may differ between the two approaches.
DeclarativeValidationTakeover featuregate.Feature = "DeclarativeValidationTakeover"
// owner: @atiratree
// kep: http://kep.k8s.io/3973

View File

@ -148,7 +148,7 @@ var defaultVersionedKubernetesFeatureGates = map[featuregate.Feature]featuregate
{Version: version.MustParse("1.33"), Default: false, PreRelease: featuregate.Beta},
},
DeclarativeValidationMismatchMetric: {
DeclarativeValidationTakeover: {
{Version: version.MustParse("1.33"), Default: false, PreRelease: featuregate.Beta},
},

View File

@ -380,7 +380,7 @@
lockToDefault: false
preRelease: Beta
version: "1.33"
- name: DeclarativeValidationMismatchMetric
- name: DeclarativeValidationTakeover
versionedSpecs:
- default: false
lockToDefault: false