* fix pods tracking and internal error checking in statefulset tests
* fix stateful set pod recreation and event spam
- do not emit events when pod reaches terminal phase
- do not try to recreate pod until the old pod has been removed from
etcd storage
* fix conflict race in statefulset rest update
statefulset controller does less requests per sync now and thus can
reconcile status faster, thus resulting in a higher chance for conflicts
We want:
- To keep test annotations simple, using both WithFeatureGate
and WithFeature should only be necessary when a test really
has requirements that go beyond "feature gate needs to be enabled".
- To run tests which depend only on feature gates being enabled
in the ci-kubernetes-e2e-kind-alpha-features resp.
ci-kubernetes-e2e-kind-beta-features, because otherwise we
may have a proliferation of many bespoke jobs which only run
very few tests. This would make testing more expensive for
Kubernetes.
- To enable those tests only once in the ci-kubernetes-e2e-kind-alpha-features
and ci-kubernetes-e2e-kind-beta-features definition instead
of having to update those each time feature gates change.
This can be achieved by adding `Feature:Alpha` resp. `Feature:Beta` as Ginkgo
labels instead of just `Alpha` and `Beta`. Then jobs which are configured to
skip tests with feature dependencies via --label-filter=!/Feature:.+/ will skip
tests which are labeled with just WithFeatureGate. The ci-kubernetes jobs
can select to include such tests with a special regexp that mimicks
a negative lookahead (see k8s.io/community/contributors/devel/sig-testing/e2e-tests.md)
Note that removing WithFeature depends on first updating job definitions to use
--label-filter or to skip based on the inline `[Alpha]` or `[Beta]` text,
otherwise tests that were previously skipped because of WithFeature might
start to run in jobs which don't have the feature gate enabled.
Single-stepping interactively through a test can be useful to understand what's
happening and to investigate the state at each step.
Similar support was added early to hack/ginkgo-e2e.sh, so the same env variable
is used again.
In commit 2f426fdba6 we added
compatibility (and tests) to deal with pre-1.20 checkpoint files.
We are now well past the end of support for pre-1.20 kubelets,
so we can get rid of this code.
Signed-off-by: Francesco Romani <fromani@redhat.com>
Even if the textlogger which writes to Ginkgo is installed as the logger in
klog, klog still does some verbosity checks itself (for example,
klog.V().Enabled).
Therefore the framework has to keep the verbosity settings in the textlogger
and in klog consistent. This is done by wrapping the Set call instead of
replacing it.
Since 43539c855f (first released in
v1.30.0-alpha.2), the test/e2e/framework manages -v and -vmodule and uses them
for a logger which writes to the Ginkgo output stream.
This did not work for test/e2e_node, because:
- logs.AddFlags(pflag.CommandLine) registers its own -v and -vmodule flags
- pflag.CommandLine.AddGoFlagSet(flag.CommandLine) skips the corresponding
flags in the flag.CommandLine
- pflag.Parse() initializes the settings in the "logs" package even though
those are not used at runtime
The solution is to not use the "logs" package.
This will allow components that don't need to watch headless services
(heavily used on ai/ml workloads) to filter them server side.
Specially useful for kubelet and kube-proxy
Change-Id: If36c2c27f2ec80db400c9133c61428d14e124f3e