Skip to content

Commit 9c6b42a

Browse files
committed
promote contextual logging to beta, enabled by default
As discussed in kubernetes/enhancements#4219 (comment) benchstat reports no significant difference in most test cases for scheduler_perf for -v3. At -v5, there is some slowdown, but that is justified because the output becomes more useful for debugging. Enabling the feature by default ensures that log output becomes better regardless whether users know and remember to enable it.
1 parent 6aac45f commit 9c6b42a

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

staging/src/k8s.io/component-base/logs/api/v1/kube_features.go

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,15 +24,17 @@ const (
2424
// owner: @pohly
2525
// kep: https://kep.k8s.io/3077
2626
// alpha: v1.24
27+
// beta: v1.30
2728
//
2829
// Enables looking up a logger from a context.Context instead of using
2930
// the global fallback logger and manipulating the logger that is
3031
// used by a call chain.
3132
ContextualLogging featuregate.Feature = "ContextualLogging"
3233

33-
// contextualLoggingDefault must remain false while in alpha. It can
34-
// become true in beta.
35-
contextualLoggingDefault = false
34+
// contextualLoggingDefault is now true because the feature reached beta
35+
// and performance comparisons showed no relevant degradation when
36+
// enabling it.
37+
contextualLoggingDefault = true
3638

3739
// Allow fine-tuning of experimental, alpha-quality logging options.
3840
//
@@ -57,7 +59,7 @@ const (
5759

5860
func featureGates() map[featuregate.Feature]featuregate.FeatureSpec {
5961
return map[featuregate.Feature]featuregate.FeatureSpec{
60-
ContextualLogging: {Default: contextualLoggingDefault, PreRelease: featuregate.Alpha},
62+
ContextualLogging: {Default: contextualLoggingDefault, PreRelease: featuregate.Beta},
6163

6264
LoggingAlphaOptions: {Default: false, PreRelease: featuregate.Alpha},
6365
LoggingBetaOptions: {Default: true, PreRelease: featuregate.Beta},

0 commit comments

Comments
 (0)