Remove special case logic in apiserver to serve all APIs when binary version is set artifically to 0.0

Kubernetes-commit: 1864e7131eca32fc9bebf20641becb467f240eca
This commit is contained in:
Joe Betz 2024-07-03 14:16:15 -04:00 committed by Kubernetes Publisher
parent e34b81ec0c
commit b754d6e7f2
1 changed files with 1 additions and 2 deletions

View File

@ -100,8 +100,7 @@ func (e *resourceExpirationEvaluator) shouldServe(gv schema.GroupVersion, versio
}
introduced, ok := versionedPtr.(introducedInterface)
// skip the introduced check for test when currentVersion is 0.0 to test all apis
if ok && (e.currentVersion.Major() > 0 || e.currentVersion.Minor() > 0) {
if ok {
majorIntroduced, minorIntroduced := introduced.APILifecycleIntroduced()
verIntroduced := apimachineryversion.MajorMinor(uint(majorIntroduced), uint(minorIntroduced))
if e.currentVersion.LessThan(verIntroduced) {