Commit Graph

116830 Commits

Author SHA1 Message Date
Madhav Jivrajani
6fd830a075 hack/tools: bump golangci-lint and consequently staticcheck
This bump is done since the latest version of staticcheck includes
a fix for a false positive reported by us, discovered while bumping
to go1.20

Signed-off-by: Madhav Jivrajani <madhav.jiv@gmail.com>
2023-06-27 14:20:41 +02:00
Patrick Ohly
1af5425696 hack: disable gomega.Consistently/Eventually check due to false positives
For example, this is a false positive that currently exists in the code base:

    test/e2e_node/dra_test.go:129:4: ginkgo-linter: use a function call in Consistently. This actually checks nothing, because Consistently receives the function returned value, instead of function itself, and this value is never changed; consider using `gomega.Consistently(ctx, e2epod.Get).WithArguments(f.ClientSet, pod).WithTimeout(podInPendingStateTimeout).Should(e2epod.BeInPhase(v1.PodPending),
    	"Pod should be in Pending state as resource preparation time outed")` instead (ginkgolinter)
    			gomega.Consistently(ctx, e2epod.Get(f.ClientSet, pod)).WithTimeout(podInPendingStateTimeout).Should(e2epod.BeInPhase(v1.PodPending),
    			^

It's a false positive because e2epod.Get returns the function that Consistently
is meant to call.

This could be worked around by assigning e2epod.Get(f.ClientSet, pod) to a
variable and then use that variable, but that is less readable.
2023-06-27 14:20:41 +02:00
Patrick Ohly
f618e61332 e2e: replace gomega.HaveLen(0) with gomega.BeEmpty()
The failure message becomes nicer. Found with the new ginkgolinter, for
example:

    test/e2e/apps/cronjob.go:113:3: ginkgo-linter: wrong length assertion; consider using `gomega.Expect(jobs.Items).To(gomega.BeEmpty())` instead (ginkgolinter)
     		gomega.Expect(jobs.Items).To(gomega.HaveLen(0))
     		^
2023-06-27 14:20:41 +02:00
Patrick Ohly
e7df337eba e2e: replace gomega.Equal(true/false) with gomega.BeTrue/BeFalse()
The failure message becomes a bit nicer. Found by the new ginkgolinter, for
example:

    test/e2e/windows/memory_limits.go:160:2: ginkgo-linter: wrong boolean assertion; consider using `gomega.Eventually(ctx, func() bool {
     eventList, err := f.ClientSet.CoreV1().Events(f.Namespace.Name).List(ctx, metav1.ListOptions{})
     ...
    }, 3*time.Minute, 10*time.Second).Should(gomega.BeTrue())` instead (ginkgolinter)
2023-06-27 14:20:20 +02:00
Patrick Ohly
8b33e8bdd1 e2e: fix gomega.Expect calls without assertions
"gomega.Expect" is not the same as "assert" in C: it always has to be combined
with a statement of what is expected.

Found with the new ginkgolinter, for example:

    test/e2e/node/pod_resize.go:242:3: ginkgo-linter: "Expect": missing assertion method. Expected "Should()", "To()", "ShouldNot()", "ToNot()" or "NotTo()" (ginkgolinter)
              gomega.Expect(found == true)
2023-06-27 14:20:20 +02:00
Kubernetes Prow Robot
9d50c0a025
Merge pull request #118889 from swetharepakula/extend-timeout
Extend Large Create Timeout to 60 min
2023-06-26 20:04:42 -07:00
Kubernetes Prow Robot
1d25ce8beb
Merge pull request #118392 from testwill/emptydir
chore: io/ioutil deprecated
2023-06-26 20:04:31 -07:00
Kubernetes Prow Robot
5e85f21e5b
Merge pull request #118888 from enj/enj/i/kms_interface_split
kmsv2: no-op: split transformer interface
2023-06-26 16:32:30 -07:00
Swetha Repakula
08198fe22b Extend Large Create Timeout to 60 min
* Load balancers are taking greater than 45 to provision
 * https://github.com/kubernetes/kubernetes/issues/118295
2023-06-26 15:32:34 -07:00
Kubernetes Prow Robot
421ca53be4
Merge pull request #118820 from logicalhan/processstart
Write process start time to prometheus options so that scraping clients can parse it first
2023-06-26 14:56:29 -07:00
Monis Khan
9354e78289
no-op: split transformer interface
Signed-off-by: Monis Khan <mok@microsoft.com>
2023-06-26 17:36:11 -04:00
Kubernetes Prow Robot
f7967af3bd
Merge pull request #118633 from sttts/sttts-controlplane-split
kube-apiserver: split apart generic control plane options
2023-06-26 13:56:29 -07:00
Dr. Stefan Schimanski
8083d0d22e
pkg/controlplane/apiserver: remove temporary import restriction of cmd/kube-apiserver 2023-06-26 21:50:38 +02:00
Dr. Stefan Schimanski
764da8a01d
FIXUP: cmd/kube-apiserver/app/options: split apart controlplane part 2023-06-26 21:50:38 +02:00
Dr. Stefan Schimanski
1b3779baa0
MOVE: cmd/kube-apiserver/app/options: split apart controlplane part 2023-06-26 21:50:37 +02:00
Kubernetes Prow Robot
96d853f4b8
Merge pull request #118870 from SataQiu/kubeadm-clean-v1beta4
kubeadm: remove unused Kind and Resource functions from v1beta4 API
2023-06-26 09:40:29 -07:00
Kubernetes Prow Robot
9f5a3f5e90
Merge pull request #118868 from sttts/sttts-kube-apiserver-options-completion-move
cmd/kube-apiserver: move options completion into options package
2023-06-26 08:14:29 -07:00
SataQiu
4298953c26 kubeadm: remove unused Kind and Resource functions from v1beta4 API 2023-06-26 22:11:52 +08:00
Kubernetes Prow Robot
d9714078f8
Merge pull request #118551 from sanposhiho/event-to-register
feature(scheduler): implement ClusterEventWithHint to filter out useless events
2023-06-26 06:41:45 -07:00
Dr. Stefan Schimanski
6e079545c4
cmd/kube-apiserver: move options completion into options package 2023-06-26 15:20:40 +02:00
Kubernetes Prow Robot
a374d893f0
Merge pull request #118840 from AhmedGrati/fix-deployment-patch-e2e-test
fix: update deployment e2e tests
2023-06-26 04:49:44 -07:00
Kubernetes Prow Robot
027ac5a426
Merge pull request #118762 from neolit123/1.28-kubeadm-add-v1beta4-boilerplate
kubeadm: add v1beta4 API boilerplate
2023-06-25 22:05:08 -07:00
Kubernetes Prow Robot
6cb0308dbf
Merge pull request #118857 from dims/better-backoff-delays-and-connection-timeout-talking-to-containerd
Better back off delays and connection timeout to talk to containerd
2023-06-25 16:53:08 -07:00
Davanum Srinivas
f7239e4095
Better back off delays and connection timeout to talk to containerd
Set up params similar to what we do in cadvisor:
e9068e3273/container/containerd/client.go (L59-L61)

Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2023-06-25 16:25:28 -04:00
Kubernetes Prow Robot
ba6d2674ca
Merge pull request #118722 from aojea/ip_leading_zeros
ipallocator bug if ips has leading zeros
2023-06-25 07:11:07 -07:00
Antonio Ojea
e4f93d8a82 ipallocator bug if ips has leading zeros
The ipallocator for the new IPAddress object use the golang big.Int
library for some math operations, like adding an offset to an IP
address.

We use the bytes array to convert between big.Int and IP addresses,
however, IP addresses are always represented as 4 or 16 bytes arrays.
Big int bytes representations just return the byte array until the
most representative number, this requires that we need to prepend
these extra bytes for IPs with leading zeros.

Change-Id: I9d539f582cae1f9f4e373b28c5b94d7a342f09c7
Signed-off-by: Antonio Ojea <aojea@google.com>
2023-06-25 13:14:46 +00:00
AhmedGrati
89a9e480f9 fix: update deployment e2e tests
Previously, we were trying to patch the deployment's ready replicas by
changing it to 0, at the same time we have 2 available replicas.
Therefore, this test fails since the ready replicas is less than the
available replicas. As a fix, we make the number of ready replicas equals to the number
of available ones.

Signed-off-by: AhmedGrati <ahmedgrati1999@gmail.com>
2023-06-24 20:48:01 +01:00
Kubernetes Prow Robot
f6416ebf26
Merge pull request #118637 from Ritikaa96/kubectl-explain-help-improvment
Details added in kubectl explain help
2023-06-23 21:19:06 -07:00
Kubernetes Prow Robot
e81c24dfb8
Merge pull request #118497 from mimowo/fix-kubelet-regression
Proceed with deletion of rejected pods after Kubelet restart
2023-06-23 14:05:07 -07:00
Kubernetes Prow Robot
c2fb8057b2
Merge pull request #118827 from serathius/fix-finder-newdesc-custom-import
Fix stable metric finder for NewDesc with custom import name
2023-06-23 10:33:23 -07:00
Kubernetes Prow Robot
98455a5b42
Merge pull request #118686 from aojea/inmidiate
always execute condition for wait.PollUntilContextTimeout with
2023-06-23 09:25:23 -07:00
Marek Siarkowicz
22258a263f Fix stable metric finder for NewDesc with custom import name 2023-06-23 16:57:56 +02:00
Kubernetes Prow Robot
baefd08919
Merge pull request #118825 from serathius/update-metric-documentation
Update metric documentation
2023-06-23 07:09:23 -07:00
Marek Siarkowicz
1384274622 Update metric documentation 2023-06-23 14:54:17 +02:00
Kubernetes Prow Robot
a48bcc06fe
Merge pull request #117064 from RomanBednar/multiple-defaults
storage class assignment should not ignore errors
2023-06-23 03:09:23 -07:00
Han Kang
07f38a3ec1 add test 2023-06-22 13:35:28 -07:00
Kubernetes Prow Robot
9325a57125
Merge pull request #118765 from mimowo/job-controller-unit-tests
Do not set jm.syncJobBatchPeriod=0 if not needed
2023-06-22 10:25:41 -07:00
Kensei Nakada
6f8d38406a feature(scheduler): implement ClusterEventWithHint to filter out useless events 2023-06-22 13:36:19 +00:00
Kubernetes Prow Robot
4f6a750bbf
Merge pull request #115813 from atiratree/controller-aliases
Introduce controller aliases for KCM and CCM
2023-06-22 04:55:39 -07:00
Michal Wozniak
8ed23558b4 Do not set jm.syncJobBatchPeriod=0 if not needed 2023-06-22 11:10:53 +02:00
Michal Wozniak
17013d3960 Review remarks to improve HandlePodCleanups in kubelet 2023-06-22 10:55:39 +02:00
Michal Wozniak
e3ee9b9adc Fix the deletion of rejected pods 2023-06-22 09:18:34 +02:00
Kubernetes Prow Robot
3e28404008
Merge pull request #118485 from MikeSpreitzer/generic-apf-strategy
Use generics to simplify pkg/registry/flowcontrol/ensurer
2023-06-21 23:57:40 -07:00
Mike Spreitzer
92a35f5bca Usse generics to simplify pkg/registry/flowcontrol/ensurer
Signed-off-by: Mike Spreitzer <mspreitz@us.ibm.com>
2023-06-22 00:56:54 -04:00
Kubernetes Prow Robot
a532733703
Merge pull request #118754 from pacoxu/fix-prometheus-client
fix metrics test with 1.16.0 prometheus client
2023-06-21 20:25:39 -07:00
Kubernetes Prow Robot
d0accc3f02
Merge pull request #118049 from helayoty/sched-queue-gated-timestamp
Unset gated podinfo InitialAttemptTimestamp in addToActiveQ
2023-06-21 17:49:39 -07:00
Kubernetes Prow Robot
3163606910
Merge pull request #118781 from tukwila/upgrade_addon_manager
upgrade image addon-manager/kube-addon-manager:v9.1.6 to v9.1.7
2023-06-21 16:49:52 -07:00
Kubernetes Prow Robot
a19153ded9
Merge pull request #118403 from skitt/ioutil-sig-storage
storage: stop using deprecated io/ioutil
2023-06-21 16:49:41 -07:00
Heba Elayoty
902c711fb4
Unset gated pod info timestamp in addToActiveQ
Signed-off-by: Heba Elayoty <hebaelayoty@gmail.com>
2023-06-21 14:16:08 -07:00
Kubernetes Prow Robot
2802bbce14
Merge pull request #118793 from serathius/test-cache-bypass
Test all cases for LIST request cache bypass
2023-06-21 13:17:52 -07:00