kubernetes/cmd
Patrick Ohly 7de1b05e85 logging: add ContextualLogging feature
InitLogs overrides the klog default and turns contextual logging off. This
ensures that it is only enabled in Kubernetes commands that explicitly enable
it via a feature gate. A feature gate for it gets defined in
k8s.io/component-base/logs and is then used by Options.ValidateAndApply.

The effect of disabling contextual logging is very limited according to
benchmarks with kube-scheduler. The feature gets added anyway to satisfy the
PRR recommendation that features should be controllable.

The following commands have support for contextual logging:
- kube-apiserver
- kube-controller-manager
- kubelet
- kube-scheduler
- component-base/logs example

Supporting a feature gate check in ValidateAndApply and not in InitLogs is a
simplification: changing InitLogs to accept a FeatureGate would have implied
changing also component-base/cli.Run. This didn't seem worthwhile because
ValidateAndApply already covers the relevant commands.
2022-03-29 13:29:57 +02:00
..
clicheck Update sig-cli OWNERS 2022-02-14 10:55:35 -07:00
cloud-controller-manager Merge pull request #107293 from dims/jan-1-owners-cleanup 2022-01-13 10:30:30 -08:00
dependencycheck replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
dependencyverifier replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
gendocs replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
genkubedocs replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
genman replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
genswaggertypedocs hack/update-bazel.sh 2021-02-28 15:17:29 -08:00
genutils hack/update-bazel.sh 2021-02-28 15:17:29 -08:00
genyaml replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
importverifier replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
kube-apiserver logging: add ContextualLogging feature 2022-03-29 13:29:57 +02:00
kube-controller-manager logging: add ContextualLogging feature 2022-03-29 13:29:57 +02:00
kube-proxy Fix health check from Google's Load Balancer 2022-03-11 22:34:59 -08:00
kube-scheduler logging: add ContextualLogging feature 2022-03-29 13:29:57 +02:00
kubeadm enhance and fix log calls 2022-03-24 11:13:50 +01:00
kubectl Update sig-cli OWNERS 2022-02-14 10:55:35 -07:00
kubectl-convert Update sig-cli OWNERS 2022-02-14 10:55:35 -07:00
kubelet logging: add ContextualLogging feature 2022-03-29 13:29:57 +02:00
kubemark Add option to bootstrap kubeconfig for hollow-node 2022-02-01 11:56:02 +00:00
linkcheck replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
preferredimports replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
yamlfmt replace deprecated io/ioutil with os and io for cmd 2022-02-01 13:59:41 +08:00
OWNERS Update dims as approver for some top level dirs 2021-11-12 08:50:24 -05:00