Revert "revert Bump DynamicKubeConfig metric deprecation to 1.23 by delta update"

This commit is contained in:
Elana Hashman 2021-08-06 08:38:56 -07:00 committed by GitHub
parent 5dd4d3c7f7
commit d2ed3b28b7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 22 deletions

View File

@ -367,7 +367,7 @@ var (
Subsystem: KubeletSubsystem,
Name: AssignedConfigKey,
Help: "The node's understanding of intended config. The count is always 1.",
DeprecatedVersion: "1.22.0",
DeprecatedVersion: "1.23.0",
StabilityLevel: metrics.ALPHA,
},
[]string{ConfigSourceLabelKey, ConfigUIDLabelKey, ConfigResourceVersionLabelKey, KubeletConfigKeyLabelKey},
@ -378,7 +378,7 @@ var (
Subsystem: KubeletSubsystem,
Name: ActiveConfigKey,
Help: "The config source the node is actively using. The count is always 1.",
DeprecatedVersion: "1.22.0",
DeprecatedVersion: "1.23.0",
StabilityLevel: metrics.ALPHA,
},
[]string{ConfigSourceLabelKey, ConfigUIDLabelKey, ConfigResourceVersionLabelKey, KubeletConfigKeyLabelKey},
@ -390,7 +390,7 @@ var (
Subsystem: KubeletSubsystem,
Name: LastKnownGoodConfigKey,
Help: "The config source the node will fall back to when it encounters certain errors. The count is always 1.",
DeprecatedVersion: "1.22.0",
DeprecatedVersion: "1.23.0",
StabilityLevel: metrics.ALPHA,
},
[]string{ConfigSourceLabelKey, ConfigUIDLabelKey, ConfigResourceVersionLabelKey, KubeletConfigKeyLabelKey},
@ -401,7 +401,7 @@ var (
Subsystem: KubeletSubsystem,
Name: ConfigErrorKey,
Help: "This metric is true (1) if the node is experiencing a configuration-related error, false (0) otherwise.",
DeprecatedVersion: "1.22.0",
DeprecatedVersion: "1.23.0",
StabilityLevel: metrics.ALPHA,
},
)

View File

@ -106,10 +106,6 @@ var _ = SIGDescribe("[Feature:DynamicKubeletConfig][NodeFeature:DynamicKubeletCo
framework.ExpectNoError(err)
beforeKC = kc
}
// show hidden metrics for release 1.22
beforeKC = updateShowHiddenMetricsForVersion(beforeKC, "1.22")
// reset the node's assigned/active/last-known-good config by setting the source to nil,
// so each test starts from a clean-slate
(&nodeConfigTestCase{
@ -122,9 +118,6 @@ var _ = SIGDescribe("[Feature:DynamicKubeletConfig][NodeFeature:DynamicKubeletCo
framework.ExpectNoError(err)
localKC = kc
}
// show hidden metrics for release 1.22
localKC = updateShowHiddenMetricsForVersion(localKC, "1.22")
})
ginkgo.AfterEach(func() {
@ -1198,14 +1191,3 @@ func (tc *nodeConfigTestCase) checkConfigMetrics(f *framework.Framework) {
return nil
}, timeout, interval).Should(gomega.BeNil())
}
func updateShowHiddenMetricsForVersion(cfg *kubeletconfig.KubeletConfiguration, version string) *kubeletconfig.KubeletConfiguration {
if cfg == nil {
return &kubeletconfig.KubeletConfiguration{
ShowHiddenMetricsForVersion: version,
}
}
cfg.ShowHiddenMetricsForVersion = version
return cfg
}